commit 3581d6e0971f037e207154fa604be2d40dee1a16 Author: Stefan Schroeder <4sschroeder@gmail.com> Date: Tue Jun 4 10:25:47 2013 +0200 ini diff --git a/jsprit-analysis/.classpath b/jsprit-analysis/.classpath new file mode 100644 index 00000000..85269988 --- /dev/null +++ b/jsprit-analysis/.classpath @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-analysis/.project b/jsprit-analysis/.project new file mode 100644 index 00000000..30c7cbba --- /dev/null +++ b/jsprit-analysis/.project @@ -0,0 +1,23 @@ + + + jsprit-analysis + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.m2e.core.maven2Nature + org.eclipse.jdt.core.javanature + + diff --git a/jsprit-analysis/.settings/org.eclipse.core.resources.prefs b/jsprit-analysis/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..afad9066 --- /dev/null +++ b/jsprit-analysis/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding//src/test/resources=UTF-8 +encoding/=UTF-8 +encoding/src=UTF-8 diff --git a/jsprit-analysis/.settings/org.eclipse.jdt.core.prefs b/jsprit-analysis/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..4a95737f --- /dev/null +++ b/jsprit-analysis/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,12 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=warning +org.eclipse.jdt.core.compiler.problem.enumIdentifier=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/jsprit-analysis/.settings/org.eclipse.m2e.core.prefs b/jsprit-analysis/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/jsprit-analysis/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/jsprit-analysis/license.txt b/jsprit-analysis/license.txt new file mode 100644 index 00000000..f258a711 --- /dev/null +++ b/jsprit-analysis/license.txt @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. \ No newline at end of file diff --git a/jsprit-analysis/pom.xml b/jsprit-analysis/pom.xml new file mode 100644 index 00000000..2539d11b --- /dev/null +++ b/jsprit-analysis/pom.xml @@ -0,0 +1,50 @@ + + + + jsprit + jsprit-project + 0.0.1 + ../jsprit-project/pom.xml + + 4.0.0 + jsprit-analysis + jar + + + + org.jfree + jfreechart + 1.0.14 + compile + + + + ${project.groupId} + jsprit-core + ${project.version} + jar + provided + + + + + diff --git a/jsprit-analysis/src/main/java/analysis/AlgorithmSearchProgressChartListener.java b/jsprit-analysis/src/main/java/analysis/AlgorithmSearchProgressChartListener.java new file mode 100644 index 00000000..980ced7a --- /dev/null +++ b/jsprit-analysis/src/main/java/analysis/AlgorithmSearchProgressChartListener.java @@ -0,0 +1,149 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package analysis; + +import java.io.File; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import org.apache.log4j.Logger; +import org.jfree.chart.ChartFactory; +import org.jfree.chart.ChartUtilities; +import org.jfree.chart.JFreeChart; +import org.jfree.chart.axis.NumberAxis; +import org.jfree.chart.axis.NumberTickUnit; +import org.jfree.chart.plot.PlotOrientation; +import org.jfree.chart.plot.XYPlot; +import org.jfree.data.Range; +import org.jfree.data.xy.XYSeries; +import org.jfree.data.xy.XYSeriesCollection; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmEndsListener; +import basics.algo.IterationEndsListener; + + +/** + * VehicleRoutingAlgorithm-Listener to record the solution-search-progress. + * + *

Register this listener in VehicleRoutingAlgorithm. + * + * @author stefan schroeder + * + */ + +public class AlgorithmSearchProgressChartListener implements IterationEndsListener, AlgorithmEndsListener { + + private static Logger log = Logger.getLogger(AlgorithmSearchProgressChartListener.class); + + private double[] bestResults; + + private double[] worstResults; + + private double[] avgResults; + + private List bestResultList = new ArrayList(); + + private List worstResultList = new ArrayList(); + + private List avgResultList = new ArrayList(); + + private String filename; + + /** + * Constructs chart listener with target png-file (filename plus path). + * + * @param pngFileName + */ + public AlgorithmSearchProgressChartListener(String pngFileName) { + super(); + this.filename = pngFileName; + } + + + @Override + public void informAlgorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + log.info("create chart " + filename); + if(bestResultList.isEmpty()){ + log.warn("cannot create chart since no results available."); + return; + } + bestResults = new double[bestResultList.size()]; + worstResults = new double[worstResultList.size()]; + avgResults = new double[avgResultList.size()]; + + double maxValue = 0.0; + double minValue = Double.MAX_VALUE; + + double[] iteration = new double[bestResultList.size()]; + for (int i = 0; i < bestResultList.size(); i++) { + if(bestResultList.get(i) < minValue) minValue = bestResultList.get(i); + if(worstResultList.get(i) < minValue) minValue = worstResultList.get(i); + if(avgResultList.get(i) < minValue) minValue = avgResultList.get(i); + + if(bestResultList.get(i) > maxValue) maxValue = bestResultList.get(i); + if(worstResultList.get(i) > maxValue) maxValue = worstResultList.get(i); + if(avgResultList.get(i) > maxValue) maxValue = avgResultList.get(i); + + bestResults[i] = bestResultList.get(i); + worstResults[i] = worstResultList.get(i); + avgResults[i] = avgResultList.get(i); + iteration[i] = i; + } + XYSeriesCollection coll = new XYSeriesCollection(); + JFreeChart chart = ChartFactory.createXYLineChart("search-progress","iterations", "results",coll, PlotOrientation.VERTICAL,true,true,false); + addSeries("bestResults", iteration, bestResults, coll); + addSeries("worstResults", iteration, worstResults, coll); + addSeries("avgResults", iteration, avgResults, coll); + + XYPlot plot = chart.getXYPlot(); + + NumberAxis yAxis = (NumberAxis) plot.getRangeAxis(); + Range rangeY = new Range(minValue-0.05*minValue,maxValue + 0.05*maxValue); + yAxis.setRange(rangeY); + + try { + ChartUtilities.saveChartAsJPEG(new File(filename), chart, 1000, 600); + } catch (IOException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + } + + private void addSeries(String string, double[] iteration, double[] results, XYSeriesCollection coll) { + XYSeries series = new XYSeries(string, true, true); + for(int i=0;i solutions) { + double worst = 0.0; + double best = Double.MAX_VALUE; + double sum = 0.0; + for(VehicleRoutingProblemSolution sol : solutions){ + if(sol.getCost() > worst) worst = sol.getCost(); + if(sol.getCost() < best) best = sol.getCost(); + sum += sol.getCost(); + } + bestResultList.add(best); + worstResultList.add(worst); + avgResultList.add(sum/(double)solutions.size()); + } + +} diff --git a/jsprit-analysis/src/main/java/analysis/SolutionPlotter.java b/jsprit-analysis/src/main/java/analysis/SolutionPlotter.java new file mode 100644 index 00000000..f1902b33 --- /dev/null +++ b/jsprit-analysis/src/main/java/analysis/SolutionPlotter.java @@ -0,0 +1,204 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package analysis; + +import java.io.File; +import java.io.IOException; +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.apache.log4j.Logger; +import org.jfree.chart.ChartFactory; +import org.jfree.chart.ChartUtilities; +import org.jfree.chart.JFreeChart; +import org.jfree.chart.axis.NumberAxis; +import org.jfree.chart.axis.NumberTickUnit; +import org.jfree.chart.plot.PlotOrientation; +import org.jfree.chart.plot.XYPlot; +import org.jfree.chart.renderer.xy.XYLineAndShapeRenderer; +import org.jfree.data.Range; +import org.jfree.data.xy.XYSeries; +import org.jfree.data.xy.XYSeriesCollection; + +import util.Coordinate; +import util.Locations; + +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + +/** + * A plotter to plot vehicle-routing-solution and routes respectively. + * + * @author stefan schroeder + * + */ +public class SolutionPlotter { + + private static Logger log = Logger.getLogger(SolutionPlotter.class); + + /** + * Plots the solution to pngFile, with title. + * + *

This can only plot if vehicles and jobs have locationIds and coordinates (@see Coordinate). Otherwise a warning message is logged + * and method returns but does not plot. + * + * @param vrp + * @param solution + * @param pngFile target path with filename. + * @see VehicleRoutingProblem, VehicleRoutingProblemSolution + */ + public static void plotSolutionAsPNG(VehicleRoutingProblem vrp, VehicleRoutingProblemSolution solution, String pngFile, String plotTitle){ + final Map locs = new HashMap(); + boolean locationsRetrieved = retrieveLocations(locs,vrp); + if(!locationsRetrieved) return; + Locations locations = new Locations(){ + + @Override + public Coordinate getCoord(String id) { + return locs.get(id); + } + + }; + plotRoutesAsPNG(solution.getRoutes(), locations, pngFile, plotTitle); + + } + + + /** + * Plots the a collection of routes to pngFile. + * + * + * @param routes + * @param locations indicating the locations for the tour-activities. + * @param pngFile target path with filename. + * @param plotTitle + * @see VehicleRoute + */ + public static void plotRoutesAsPNG(Collection routes, Locations locations, String pngFile, String plotTitle) { + log.info("plot routes to " + pngFile); + XYSeriesCollection coll = new XYSeriesCollection(); + int counter = 1; + double maxX = 0; + double minX = Double.MAX_VALUE; + double maxY = 0; + double minY = Double.MAX_VALUE; + for(VehicleRoute route : routes){ + if(route.isEmpty()) continue; + XYSeries series = new XYSeries(counter, false, true); + + Coordinate startCoord = locations.getCoord(route.getStart().getLocationId()); + series.add(startCoord.getX(), startCoord.getY()); + if(startCoord.getX() > maxX) maxX = startCoord.getX(); + if(startCoord.getY() > maxY) maxY = startCoord.getY(); + if(startCoord.getX() < minX) minX = startCoord.getX(); + if(startCoord.getY() < minY) minY = startCoord.getY(); + + for(TourActivity act : route.getTourActivities().getActivities()){ + Coordinate coord = locations.getCoord(act.getLocationId()); + series.add(coord.getX(), coord.getY()); + if(coord.getX() > maxX) maxX = coord.getX(); + if(coord.getY() > maxY) maxY = coord.getY(); + if(coord.getX() < minX) minX = coord.getX(); + if(coord.getY() < minY) minY = coord.getY(); + } + + Coordinate endCoord = locations.getCoord(route.getEnd().getLocationId()); + series.add(endCoord.getX(), endCoord.getY()); + if(endCoord.getX() > maxX) maxX = endCoord.getX(); + if(endCoord.getY() > maxY) maxY = endCoord.getY(); + if(endCoord.getX() < minX) minX = endCoord.getX(); + if(endCoord.getY() < minY) minY = endCoord.getY(); + + coll.addSeries(series); + counter++; + } + JFreeChart chart = ChartFactory.createXYLineChart(plotTitle,"x-coordinate", "y-coordinate",coll, PlotOrientation.VERTICAL,true,true,false); + + XYPlot plot = chart.getXYPlot(); + + XYLineAndShapeRenderer renderer = (XYLineAndShapeRenderer) plot.getRenderer(); + renderer.setBaseShapesVisible(true); + + NumberAxis xAxis = (NumberAxis) plot.getDomainAxis(); + xAxis.setTickUnit(new NumberTickUnit(10)); +// Range rangeX = new Range(minX - 0.05*minX, maxX+0.05*maxX); + Range rangeX = new Range(minX, maxX); + xAxis.setRange(rangeX); + + NumberAxis yAxis = (NumberAxis) plot.getRangeAxis(); +// yAxis.setTickUnit(new NumberTickUnit(10)); +// Range rangeY = new Range(minY-0.05*minY,maxY + 0.05*maxY); + Range rangeY = new Range(minY,maxY); + yAxis.setRange(rangeY); + try { + ChartUtilities.saveChartAsPNG(new File(pngFile), chart, 1000, 600); + } catch (IOException e) { + log.error("cannot plot"); + log.error(e); + e.printStackTrace(); + + } + } + + private static boolean retrieveLocations(Map locs, VehicleRoutingProblem vrp) { + for(Vehicle v : vrp.getVehicles()){ + String locationId = v.getLocationId(); + if(locationId == null){ + log.warn("cannot plot solution, since vehicle " + v + " has no locationId."); + return false; + } + Coordinate coord = v.getCoord(); + if(coord == null){ + log.warn("cannot plot solution, since vehicle " + v + " has no location-coordinate."); + return false; + } + locs.put(locationId, coord); + } + for(Job j : vrp.getJobs().values()){ + if(j instanceof Service){ + String locationId = ((Service) j).getLocationId(); + if(locationId == null){ + log.warn("cannot plot solution, since job " + j + " has no locationId."); + return false; + } + Coordinate coord = ((Service) j).getCoord(); + if(coord == null){ + log.warn("cannot plot solution, since job " + j + " has no location-coordinate."); + return false; + } + locs.put(locationId, coord); + } + else{ + throw new IllegalStateException("job is not a service. this is not supported yet."); + } + } + return true; + } + + +} diff --git a/jsprit-analysis/src/main/java/analysis/SolutionPrinter.java b/jsprit-analysis/src/main/java/analysis/SolutionPrinter.java new file mode 100644 index 00000000..01476de8 --- /dev/null +++ b/jsprit-analysis/src/main/java/analysis/SolutionPrinter.java @@ -0,0 +1,91 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package analysis; + +import basics.VehicleRoutingProblemSolution; +import basics.route.DefaultVehicleRouteCostCalculator; +import basics.route.VehicleRoute; + +/** + * Printer to print the details of a vehicle-routing-problem solution. + * + * @author stefan schroeder + * + */ +public class SolutionPrinter { + + /** + * Enum to indicate verbose-level. + * + *

Print.CONCISE and Print.VERBOSE are available. + * + * @author stefan schroeder + * + */ + public enum Print { + + CONCISE,VERBOSE + } + + /** + * Prints costs and #vehicles to stdout (System.out.println). + * + * @param solution + */ + public static void print(VehicleRoutingProblemSolution solution){ + System.out.println("[costs="+solution.getCost() + "]"); + System.out.println("[#vehicles="+solution.getRoutes().size() + "]"); + + } + + /** + * Prints the details of the solution according to a print-level, i.e. Print.CONCISE or PRINT.VERBOSE. + * + *

CONCISE prints total-costs and #vehicles. + *

VERBOSE prints the route-details additionally. If the DefaultVehicleRouteCostCalculator (which is the standard-calculator) + * is used in VehicleRoute, then route-costs are differentiated further between transport, activity, vehicle, driver and other-costs. + * + * @param solution + * @param level + */ + public static void print(VehicleRoutingProblemSolution solution, Print level){ + if(level.equals(Print.CONCISE)){ + print(solution); + } + else{ + print(solution); + System.out.println("routes"); + int routeCount = 1; + for(VehicleRoute route : solution.getRoutes()){ + System.out.println("[route="+routeCount+"][departureTime="+route.getStart().getEndTime()+"[total=" + route.getCost() + "]"); + if(route.getVehicleRouteCostCalculator() instanceof DefaultVehicleRouteCostCalculator){ + DefaultVehicleRouteCostCalculator defaultCalc = (DefaultVehicleRouteCostCalculator) route.getVehicleRouteCostCalculator(); + System.out.println("[transport=" + defaultCalc.getTpCosts() + "][activity=" + defaultCalc.getActCosts() + + "][vehicle=" + defaultCalc.getVehicleCosts() + "][driver=" + defaultCalc.getDriverCosts() + "][other=" + defaultCalc.getOther() + "]"); + } + routeCount++; + } + } + + + } + +} diff --git a/jsprit-analysis/src/main/java/analysis/StopWatch.java b/jsprit-analysis/src/main/java/analysis/StopWatch.java new file mode 100644 index 00000000..bbc45356 --- /dev/null +++ b/jsprit-analysis/src/main/java/analysis/StopWatch.java @@ -0,0 +1,80 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package analysis; + +import java.util.Collection; + +import org.apache.log4j.Logger; + +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmEndsListener; +import basics.algo.AlgorithmStartsListener; + +public class StopWatch implements AlgorithmStartsListener, AlgorithmEndsListener{ + + private static Logger log = Logger.getLogger(StopWatch.class); + + private double ran; + + private double startTime; + + + @Override + public void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + reset(); + start(); + } + + public double getCompTimeInSeconds(){ + return (ran)/1000.0; + } + + @Override + public void informAlgorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + stop(); + log.info("computation time [in sec]: " + getCompTimeInSeconds()); + } + + public void stop(){ + ran += System.currentTimeMillis() - startTime; + } + + public void start(){ + startTime = System.currentTimeMillis(); + } + + public void reset(){ + startTime = 0; + ran = 0; + } + + @Override + public String toString() { + return "stopWatch: " + getCompTimeInSeconds() + " sec"; + } + + public double getCurrTimeInSeconds() { + return (System.currentTimeMillis()-startTime)/1000.0; + } + +} diff --git a/jsprit-core/.DS_Store b/jsprit-core/.DS_Store new file mode 100644 index 00000000..b365a10f Binary files /dev/null and b/jsprit-core/.DS_Store differ diff --git a/jsprit-core/.classpath b/jsprit-core/.classpath new file mode 100644 index 00000000..7fcefca3 --- /dev/null +++ b/jsprit-core/.classpath @@ -0,0 +1,30 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/.project b/jsprit-core/.project new file mode 100644 index 00000000..b663793f --- /dev/null +++ b/jsprit-core/.project @@ -0,0 +1,29 @@ + + + jsprit-core + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.maven.ide.eclipse.maven2Builder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.m2e.core.maven2Nature + org.eclipse.jdt.core.javanature + org.maven.ide.eclipse.maven2Nature + + diff --git a/jsprit-core/.settings/org.eclipse.core.resources.prefs b/jsprit-core/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..afad9066 --- /dev/null +++ b/jsprit-core/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding//src/test/resources=UTF-8 +encoding/=UTF-8 +encoding/src=UTF-8 diff --git a/jsprit-core/.settings/org.eclipse.jdt.core.prefs b/jsprit-core/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..69c31cd4 --- /dev/null +++ b/jsprit-core/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,8 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/jsprit-core/.settings/org.eclipse.m2e.core.prefs b/jsprit-core/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/jsprit-core/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/jsprit-core/.settings/org.maven.ide.eclipse.prefs b/jsprit-core/.settings/org.maven.ide.eclipse.prefs new file mode 100644 index 00000000..fee42859 --- /dev/null +++ b/jsprit-core/.settings/org.maven.ide.eclipse.prefs @@ -0,0 +1,9 @@ +#Fri Mar 15 09:09:12 CET 2013 +activeProfiles= +eclipse.preferences.version=1 +fullBuildGoals=process-test-resources +includeModules=false +resolveWorkspaceProjects=true +resourceFilterGoals=process-resources resources\:testResources +skipCompilerPlugin=true +version=1 diff --git a/jsprit-core/license.txt b/jsprit-core/license.txt new file mode 100644 index 00000000..f258a711 --- /dev/null +++ b/jsprit-core/license.txt @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. \ No newline at end of file diff --git a/jsprit-core/pom.xml b/jsprit-core/pom.xml new file mode 100644 index 00000000..7b0fee12 --- /dev/null +++ b/jsprit-core/pom.xml @@ -0,0 +1,60 @@ + + + + jsprit + jsprit-project + 0.0.1 + ../jsprit-project/pom.xml + + 4.0.0 + jsprit-core + jsprit-core + + + + + org.apache.commons + commons-math + 2.2 + jar + compile + + + + commons-configuration + commons-configuration + 1.9 + jar + compile + + + + xerces + xerces + 2.4.0 + + + + + + + diff --git a/jsprit-core/src/main/java/algorithms/AbstractInsertionStrategy.java b/jsprit-core/src/main/java/algorithms/AbstractInsertionStrategy.java new file mode 100644 index 00000000..f2dfca54 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/AbstractInsertionStrategy.java @@ -0,0 +1,95 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.List; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.algo.InsertionEndsListener; +import basics.algo.InsertionListener; +import basics.algo.InsertionStartsListener; +import basics.algo.JobInsertedListener; +import basics.route.VehicleRoute; + + + + +abstract class AbstractInsertionStrategy implements InsertionStrategy{ + + private static Logger log = Logger.getLogger(AbstractInsertionStrategy.class); + + private Collection listener = new ArrayList(); + + public abstract RouteAlgorithm getRouteAlgorithm(); + + public void informJobInserted(int nOfJobs2Recreate, Job insertedJob, VehicleRoute insertedIn){ + for(InsertionListener l : listener){ + if(l instanceof JobInsertedListener){ + ((JobInsertedListener)l).informJobInserted(nOfJobs2Recreate, insertedJob, insertedIn); + } + } + } + + public void informBeforeJobInsertion(Job job, InsertionData data, VehicleRoute route){ + for(InsertionListener l : listener){ + if(l instanceof BeforeJobInsertionListener){ + ((BeforeJobInsertionListener)l).informBeforeJobInsertion(job, data, route); + } + } + } + + public void informInsertionStarts(Collection vehicleRoutes, int nOfJobs2Recreate){ + for(InsertionListener l : listener){ + if(l instanceof InsertionStartsListener){ + ((InsertionStartsListener)l).informInsertionStarts(vehicleRoutes,nOfJobs2Recreate); + } + } + } + + public void informInsertionEndsListeners(Collection vehicleRoutes) { + for(InsertionListener l : listener){ + if(l instanceof InsertionEndsListener){ + ((InsertionEndsListener)l).informInsertionEnds(vehicleRoutes); + } + } + } + + public Collection getListener() { + return Collections.unmodifiableCollection(listener); + } + + public void addListener(InsertionListener l){ + log.info("add insertion-listener " + l); + listener.add(l); + } + + public void addAllListener(List list) { + for(InsertionListener l : list) addListener(l); + } + + + +} diff --git a/jsprit-core/src/main/java/algorithms/AuxilliaryCostCalculator.java b/jsprit-core/src/main/java/algorithms/AuxilliaryCostCalculator.java new file mode 100644 index 00000000..43c2dc04 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/AuxilliaryCostCalculator.java @@ -0,0 +1,111 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Iterator; +import java.util.List; + +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.TourActivity; +import basics.route.Vehicle; + + +final class AuxilliaryCostCalculator { + + private final VehicleRoutingTransportCosts routingCosts; + + private final VehicleRoutingActivityCosts activityCosts; + + public AuxilliaryCostCalculator(final VehicleRoutingTransportCosts routingCosts, final VehicleRoutingActivityCosts costFunction) { + super(); + this.routingCosts = routingCosts; + this.activityCosts = costFunction; + } + + /** + * + * @param path + * @param depTime + * @param driver + * @param vehicle + * @return + */ + public double costOfPath(final List path, final double depTime, final Driver driver, final Vehicle vehicle){ + if(path.isEmpty()){ + return 0.0; + } + double cost = 0.0; + Iterator actIter = path.iterator(); + TourActivity prevAct = actIter.next(); + double startCost = 0.0; + cost += startCost; + double departureTimePrevAct = depTime; + while(actIter.hasNext()){ + TourActivity act = actIter.next(); + double transportCost = routingCosts.getTransportCost(prevAct.getLocationId(), act.getLocationId(), departureTimePrevAct, driver, vehicle); + double transportTime = routingCosts.getTransportTime(prevAct.getLocationId(), act.getLocationId(), departureTimePrevAct, driver, vehicle); + cost += transportCost; + double actStartTime = departureTimePrevAct + transportTime; + double earliestOperationStartTime = Math.max(actStartTime, act.getTheoreticalEarliestOperationStartTime()); + double actEndTime = earliestOperationStartTime + act.getOperationTime(); + departureTimePrevAct = actEndTime; + cost += activityCosts.getActivityCost(act, actStartTime, driver, vehicle); + prevAct = act; + } + return cost; + } + + public double costOfPath(String startLocationId, final double startTime, final List path, String endLocationId, final Driver driver, final Vehicle vehicle){ + if(path.isEmpty()){ + return 0.0; + } + double cost = 0.0; +// Iterator actIter = path.iterator(); + String prevActLocation = startLocationId; +// TourActivity prevAct = actIter.next(); + double startCost = 0.0; + cost += startCost; + double departureTimePrevAct = startTime; + for(TourActivity act : path){ +// TourActivity act = actIter.next(); + double transportCost = routingCosts.getTransportCost(prevActLocation, act.getLocationId(), departureTimePrevAct, driver, vehicle); + double transportTime = routingCosts.getTransportTime(prevActLocation, act.getLocationId(), departureTimePrevAct, driver, vehicle); + cost += transportCost; + double actStartTime = departureTimePrevAct + transportTime; + double earliestOperationStartTime = Math.max(actStartTime, act.getTheoreticalEarliestOperationStartTime()); + double actEndTime = earliestOperationStartTime + act.getOperationTime(); + departureTimePrevAct = actEndTime; + cost += activityCosts.getActivityCost(act, actStartTime, driver, vehicle); + prevActLocation = act.getLocationId(); + } + + /* + *!!! ENDLOCATION + => Start u. End können primitiv sein. + + */ + + return cost; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/BeforeJobInsertionListener.java b/jsprit-core/src/main/java/algorithms/BeforeJobInsertionListener.java new file mode 100644 index 00000000..e6c3f8cb --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/BeforeJobInsertionListener.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.algo.InsertionListener; +import basics.route.VehicleRoute; + +interface BeforeJobInsertionListener extends InsertionListener{ + + public void informBeforeJobInsertion(Job job, InsertionData data, VehicleRoute route); + +} diff --git a/jsprit-core/src/main/java/algorithms/BestInsertion.java b/jsprit-core/src/main/java/algorithms/BestInsertion.java new file mode 100644 index 00000000..7522cc60 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/BestInsertion.java @@ -0,0 +1,160 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Random; + +import org.apache.log4j.Logger; + +import util.RandomNumberGeneration; +import algorithms.InsertionData.NoInsertionFound; +import basics.Job; +import basics.route.VehicleRoute; + + + +/** + * Simplest recreation strategy. All removed customers are inserted where + * insertion costs are minimal. I.e. each tour-agent is asked for minimal + * marginal insertion costs. The tour-agent offering the lowest marginal + * insertion costs gets the customer/shipment. + * + * @author stefan schroeder + * + */ + +final class BestInsertion extends AbstractInsertionStrategy{ + + public static BestInsertion newInstance(RouteAlgorithm routeAlgorithm){ + return new BestInsertion(routeAlgorithm); + } + + private static Logger logger = Logger.getLogger(BestInsertion.class); + + private Random random = RandomNumberGeneration.getRandom(); + + private RouteAlgorithm routeAlgorithm; + + private Map experimentalPreferredRoute = new HashMap(); + + public void setExperimentalPreferredRoute(Map experimentalPreferredRoute) { + this.experimentalPreferredRoute = experimentalPreferredRoute; + } + + private boolean allowUnassignedJobs = false; + + private boolean fixRouteSet = false; + + private boolean minVehiclesFirst = false; + + public void setFixRouteSet(boolean fixRouteSet) { + this.fixRouteSet = fixRouteSet; + } + + public void setRandom(Random random) { + this.random = random; + } + + public BestInsertion(RouteAlgorithm routeAlgorithm) { + super(); + this.routeAlgorithm = routeAlgorithm; + logger.info("initialise " + this); + } + + public RouteAlgorithm getRouteAlgorithm(){ + return routeAlgorithm; + } + + @Override + public String toString() { + return "[name=bestInsertion]"; + } + + @Override + public void run(Collection vehicleRoutes, Collection unassignedJobs, double result2beat) { + List unassignedJobList = new ArrayList(unassignedJobs); + Collections.shuffle(unassignedJobList, random); + informInsertionStarts(vehicleRoutes,unassignedJobs.size()); + int inserted = 0; + List reasons = new ArrayList(); + for(Job unassignedJob : unassignedJobList){ + + VehicleRoute insertIn = null; + Insertion bestInsertion = null; + double bestInsertionCost = Double.MAX_VALUE; + for(VehicleRoute vehicleRoute : vehicleRoutes){ + InsertionData iData = routeAlgorithm.calculateBestInsertion(vehicleRoute, unassignedJob, bestInsertionCost); + if(iData instanceof NoInsertionFound) { + continue; + } + if(iData.getInsertionCost() < bestInsertionCost){ + bestInsertion = new Insertion(vehicleRoute,iData); + bestInsertionCost = iData.getInsertionCost(); + } + } + if(!minVehiclesFirst){ + VehicleRoute newRoute = VehicleRoute.emptyRoute(); + InsertionData newIData = routeAlgorithm.calculateBestInsertion(newRoute, unassignedJob, Double.MAX_VALUE); + if(newIData.getInsertionCost() < bestInsertionCost){ + bestInsertion = new Insertion(newRoute,newIData); + bestInsertionCost = newIData.getInsertionCost(); + vehicleRoutes.add(newRoute); + } + } + if(bestInsertion != null){ + informBeforeJobInsertion(unassignedJob, bestInsertion.getInsertionData(), bestInsertion.getRoute()); + insertIn = bestInsertion.getRoute(); +// logger.debug("insert job="+unassignedJob+" at index=" + bestInsertion.getInsertionData().getInsertionIndex() + " delta cost=" + bestInsertion.getInsertionData().getInsertionCost()); + routeAlgorithm.insertJob(unassignedJob, bestInsertion.getInsertionData(), bestInsertion.getRoute()); + } + else { + if(fixRouteSet){ + if(allowUnassignedJobs) logger.warn("cannot insert job yet " + unassignedJob); + else throw new IllegalStateException("given the vehicles, could not insert job\n"); + } + else{ + VehicleRoute newRoute = VehicleRoute.emptyRoute(); + InsertionData bestI = routeAlgorithm.calculateBestInsertion(newRoute, unassignedJob, Double.MAX_VALUE); + if(bestI instanceof InsertionData.NoInsertionFound){ + if(allowUnassignedJobs){ + logger.warn("cannot insert job yet " + unassignedJob); + } + else { + for(String s : reasons){ + System.out.println("reason="+s); + } + throw new IllegalStateException("given the vehicles, could not insert job\n" + + "\t" + unassignedJob + "\n\t"); + } + } + else{ + insertIn = newRoute; + informBeforeJobInsertion(unassignedJob,bestI,newRoute); + routeAlgorithm.insertJob(unassignedJob,bestI,newRoute); + vehicleRoutes.add(newRoute); + } + } + } + inserted++; + informJobInserted((unassignedJobList.size()-inserted), unassignedJob, insertIn); + } + informInsertionEndsListeners(vehicleRoutes); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/BestInsertionConcurrent.java b/jsprit-core/src/main/java/algorithms/BestInsertionConcurrent.java new file mode 100644 index 00000000..61cd1d27 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/BestInsertionConcurrent.java @@ -0,0 +1,191 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.Collections; +import java.util.List; +import java.util.Random; +import java.util.concurrent.Callable; +import java.util.concurrent.CompletionService; +import java.util.concurrent.ExecutionException; +import java.util.concurrent.ExecutorCompletionService; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Future; + +import org.apache.log4j.Logger; + +import util.RandomNumberGeneration; +import algorithms.InsertionData.NoInsertionFound; +import basics.Job; +import basics.route.VehicleRoute; + + + +/** + * Simplest recreation strategy. All removed customers are inserted where + * insertion costs are minimal. I.e. each tour-agent is asked for minimal + * marginal insertion costs. The tour-agent offering the lowest marginal + * insertion costs gets the customer/shipment. + * + * @author stefan schroeder + * + */ + +final class BestInsertionConcurrent extends AbstractInsertionStrategy{ + + + static class Batch { + List routes = new ArrayList(); + + } + + private static Logger logger = Logger.getLogger(BestInsertionConcurrent.class); + + private Random random = RandomNumberGeneration.getRandom(); + + private RouteAlgorithm routeAlgorithm; + +// private ExecutorService executor; + + private int nuOfBatches; + + private ExecutorCompletionService completionService; + + public void setRandom(Random random) { + this.random = random; + } + + public BestInsertionConcurrent(RouteAlgorithm routeAlgorithm, ExecutorService executor, int nuOfThreads) { + super(); + this.routeAlgorithm = routeAlgorithm; +// this.executor = executor; + logger.info("initialise " + this); + this.nuOfBatches = nuOfThreads; + completionService = new ExecutorCompletionService(executor); + } + + @Override + public String toString() { + return "[name=concurrentBestInsertion]"; + } + + @Override + public void run(Collection vehicleRoutes, Collection unassignedJobs, double result2beat) { + List unassignedJobList = new ArrayList(unassignedJobs); + Collections.shuffle(unassignedJobList, random); + informInsertionStarts(vehicleRoutes,unassignedJobs.size()); + + int inserted = 0; + for(final Job unassignedJob : unassignedJobList){ + VehicleRoute insertIn = null; + Insertion bestInsertion = null; + double bestInsertionCost = Double.MAX_VALUE; + + List batches = distributeRoutes(vehicleRoutes,nuOfBatches); + + for(final Batch batch : batches){ + completionService.submit(new Callable() { + + @Override + public Insertion call() throws Exception { + return getBestInsertion(batch,unassignedJob); + } + + }); + + } + + try{ + for(int i=0;i futureIData = completionService.take(); + Insertion insertion = futureIData.get(); + if(insertion == null) continue; + if(insertion.getInsertionData().getInsertionCost() < bestInsertionCost){ + bestInsertion = insertion; + bestInsertionCost = insertion.getInsertionData().getInsertionCost(); + } + } + } + catch(InterruptedException e){ + Thread.currentThread().interrupt(); + } + catch (ExecutionException e) { + e.printStackTrace(); + logger.error(e.getCause().toString()); + System.exit(1); + } + + if(bestInsertion != null){ + informBeforeJobInsertion(unassignedJob, bestInsertion.getInsertionData(), bestInsertion.getRoute()); + insertIn = bestInsertion.getRoute(); +// logger.debug("insert job="+unassignedJob+" at index=" + bestInsertion.getInsertionData().getInsertionIndex() + " delta cost=" + bestInsertion.getInsertionData().getInsertionCost()); + routeAlgorithm.insertJob(unassignedJob, bestInsertion.getInsertionData(), bestInsertion.getRoute()); + } + else { + VehicleRoute newRoute = VehicleRoute.emptyRoute(); + InsertionData bestI = routeAlgorithm.calculateBestInsertion(newRoute, unassignedJob, Double.MAX_VALUE); + if(bestI instanceof InsertionData.NoInsertionFound) + throw new IllegalStateException("given the vehicles, could not create a valid solution.\n\tthe reason might be" + + " inappropriate vehicle capacity.\n\tthe job that does not fit in any vehicle anymore is \n\t" + unassignedJob); + insertIn = newRoute; + informBeforeJobInsertion(unassignedJob,bestI,newRoute); + routeAlgorithm.insertJob(unassignedJob,bestI,newRoute); + vehicleRoutes.add(newRoute); + } + inserted++; + informJobInserted((unassignedJobList.size()-inserted), unassignedJob, insertIn); + } + + } + + private Insertion getBestInsertion(Batch batch, Job unassignedJob) { + Insertion bestInsertion = null; + double bestInsertionCost = Double.MAX_VALUE; + for(VehicleRoute vehicleRoute : batch.routes){ + InsertionData iData = routeAlgorithm.calculateBestInsertion(vehicleRoute, unassignedJob, bestInsertionCost); + if(iData instanceof NoInsertionFound) continue; + if(iData.getInsertionCost() < bestInsertionCost){ + bestInsertion = new Insertion(vehicleRoute,iData); + bestInsertionCost = iData.getInsertionCost(); + } + } + return bestInsertion; + } + + private List distributeRoutes(Collection vehicleRoutes, int nuOfBatches) { + List batches = new ArrayList(); + for(int i=0;i getLatestOperationStart(nextAct)){ + activityInsertionCosts = Double.MAX_VALUE; + } + else if(vehicleRoute.isEmpty()){ + activityInsertionCosts = totalCosts; + } + else{ + double oldCostOfPrevAct; + if(prevIsStart) oldCostOfPrevAct = 0.0; + else oldCostOfPrevAct = state(prevAct).getCurrentCost(); + double oldCostOfNextAct; + if(nextAct instanceof End) oldCostOfNextAct = routeStates.getRouteState(vehicleRoute).getCosts(); + else oldCostOfNextAct = state(nextAct).getCurrentCost(); + activityInsertionCosts = (totalCosts) - (oldCostOfNextAct-oldCostOfPrevAct); + } + return activityInsertionCosts; + } + + private ActivityState state(TourActivity act) { + return routeStates.getState(act); + } + + private double getLatestOperationStart(TourActivity act) { + if(state(act) != null){ + return state(act).getLatestOperationStart(); + } + return act.getTheoreticalLatestOperationStartTime(); + } + + @Override + public String toString() { + return "[name=calculatesHardTimeWindowActivityInsertion]"; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertion.java b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertion.java new file mode 100644 index 00000000..c2c133a2 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertion.java @@ -0,0 +1,209 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.apache.log4j.Logger; + +import util.Neighborhood; + +import algorithms.RouteStates.ActivityState; +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.End; +import basics.route.ServiceActivity; +import basics.route.Start; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; +import basics.route.VehicleImpl.NoVehicle; + + + +final class CalculatesServiceInsertion implements JobInsertionCalculator{ + + private static final Logger logger = Logger.getLogger(CalculatesServiceInsertion.class); + + private RouteStates routeStates; + + private VehicleRoutingTransportCosts routingCosts; + + private VehicleRoutingActivityCosts activityCosts; + + private Start start; + + private End end; + + private Neighborhood neighborhood = new Neighborhood() { + + @Override + public boolean areNeighbors(String location1, String location2) { + return true; + } + }; + + + + public void setNeighborhood(Neighborhood neighborhood) { + this.neighborhood = neighborhood; + logger.info("initialise neighborhood " + neighborhood); + } + + public void setActivityStates(RouteStates actStates){ + this.routeStates = actStates; + } + + public ActivityState state(TourActivity act){ + return routeStates.getState(act); + } + + public CalculatesServiceInsertion(VehicleRoutingTransportCosts vehicleRoutingTransportCosts, VehicleRoutingActivityCosts vehicleRoutingActivityCosts) { + super(); + this.routingCosts = vehicleRoutingTransportCosts; + this.activityCosts = vehicleRoutingActivityCosts; + logger.info("initialise " + this); + } + + @Override + public String toString() { + return "[name=calculatesServiceInsertion]"; + } + + /** + * Calculates the marginal cost of inserting job i locally. This is based on the + * assumption that cost changes can entirely covered by only looking at the predecessor i-1 and its successor i+1. + * + */ + @Override + public InsertionData calculate(final VehicleRoute currentRoute, final Job jobToInsert, final Vehicle newVehicle, double newVehicleDepartureTime, final Driver newDriver, final double bestKnownCosts) { + if(jobToInsert == null) throw new IllegalStateException("jobToInsert is missing."); + if(newVehicle == null || newVehicle instanceof NoVehicle) throw new IllegalStateException("newVehicle is missing."); + + TourActivities tour = currentRoute.getTourActivities(); + double bestCost = bestKnownCosts; + Service service = (Service)jobToInsert; + + if(routeStates.getRouteState(currentRoute).getLoad() + service.getCapacityDemand() > newVehicle.getCapacity()){ + return InsertionData.noInsertionFound(); + } + int insertionIndex = InsertionData.NO_INDEX; + + TourActivity deliveryAct2Insert = ServiceActivity.newInstance(service); +// TourActivity deliveryAct2Insert = actStates.getActivity(service, true); + + initialiseStartAndEnd(newVehicle, newVehicleDepartureTime); + + TourActivity prevAct = start; + double prevCostInOriginalTour = 0.0; + int actIndex = 0; + for(TourActivity nextAct : tour.getActivities()){ + double nextCostInOriginalTour = state(nextAct).getCurrentCost(); + if(neighborhood.areNeighbors(deliveryAct2Insert.getLocationId(), prevAct.getLocationId()) && neighborhood.areNeighbors(deliveryAct2Insert.getLocationId(), nextAct.getLocationId())){ + double mc = calculate(tour, prevAct, nextAct, deliveryAct2Insert, newDriver, newVehicle, bestCost, nextCostInOriginalTour - prevCostInOriginalTour); + if(mc < bestCost){ + bestCost = mc; + insertionIndex = actIndex; + } + } + prevCostInOriginalTour = nextCostInOriginalTour; + prevAct = nextAct; + actIndex++; + } + End nextAct = end; + if(neighborhood.areNeighbors(deliveryAct2Insert.getLocationId(), prevAct.getLocationId()) && neighborhood.areNeighbors(deliveryAct2Insert.getLocationId(), nextAct.getLocationId())){ + double mc = calculate(tour, prevAct, nextAct, deliveryAct2Insert, newDriver, newVehicle, bestCost, routeStates.getRouteState(currentRoute).getCosts() - prevCostInOriginalTour); + if(mc < bestCost){ + bestCost = mc; + insertionIndex = actIndex; + } + } + + if(insertionIndex == InsertionData.NO_INDEX) { + return InsertionData.noInsertionFound(); + } + InsertionData insertionData = new InsertionData(bestCost, InsertionData.NO_INDEX, insertionIndex, newVehicle, newDriver); + insertionData.setVehicleDepartureTime(newVehicleDepartureTime); + return insertionData; + } + + private void initialiseStartAndEnd(final Vehicle newVehicle, + double newVehicleDepartureTime) { + if(start == null){ + start = Start.newInstance(newVehicle.getLocationId(), newVehicle.getEarliestDeparture(), newVehicle.getLatestArrival()); + start.setEndTime(newVehicleDepartureTime); + } + else{ + start.setLocationId(newVehicle.getLocationId()); + start.setTheoreticalEarliestOperationStartTime(newVehicle.getEarliestDeparture()); + start.setTheoreticalLatestOperationStartTime(newVehicle.getLatestArrival()); + start.setEndTime(newVehicleDepartureTime); + } + + if(end == null){ + end = End.newInstance(newVehicle.getLocationId(), 0.0, newVehicle.getLatestArrival()); + } + else{ + end.setLocationId(newVehicle.getLocationId()); + end.setTheoreticalEarliestOperationStartTime(newVehicleDepartureTime); + end.setTheoreticalLatestOperationStartTime(newVehicle.getLatestArrival()); + } + } + + public double calculate(TourActivities tour, TourActivity prevAct, TourActivity nextAct, TourActivity newAct, Driver driver, Vehicle vehicle, double bestKnownCosts, double costWithoutNewJob) { + + double tp_costs_prevAct_newAct = routingCosts.getTransportCost(prevAct.getLocationId(), newAct.getLocationId(), prevAct.getEndTime(), driver, vehicle); + double tp_time_prevAct_newAct = routingCosts.getTransportTime(prevAct.getLocationId(), newAct.getLocationId(), prevAct.getEndTime(), driver, vehicle); + + double newAct_arrTime = prevAct.getEndTime() + tp_time_prevAct_newAct; + double newAct_operationStartTime = Math.max(newAct_arrTime, newAct.getTheoreticalEarliestOperationStartTime()); + + double newAct_endTime = newAct_operationStartTime + newAct.getOperationTime(); + + double act_costs_newAct = activityCosts.getActivityCost(newAct, newAct_arrTime, driver, vehicle); + + if((tp_costs_prevAct_newAct + act_costs_newAct - costWithoutNewJob) > bestKnownCosts){ + return Double.MAX_VALUE; + } + + double tp_costs_newAct_nextAct = routingCosts.getTransportCost(newAct.getLocationId(), nextAct.getLocationId(), newAct_endTime, driver, vehicle); + double tp_time_newAct_nextAct = routingCosts.getTransportTime(newAct.getLocationId(), nextAct.getLocationId(), newAct_endTime, driver, vehicle); + + double nextAct_arrTime = newAct_endTime + tp_time_newAct_nextAct; + double act_costs_nextAct = activityCosts.getActivityCost(nextAct, nextAct_arrTime, driver, vehicle); + + double activityInsertionCosts; + + double totalCosts = tp_costs_prevAct_newAct + tp_costs_newAct_nextAct + act_costs_newAct + act_costs_nextAct; + + if(totalCosts - costWithoutNewJob > bestKnownCosts){ + activityInsertionCosts = Double.MAX_VALUE; + } + if(nextAct_arrTime > getLatestOperationStart(nextAct)){ + activityInsertionCosts = Double.MAX_VALUE; + } + else{ + activityInsertionCosts = totalCosts - costWithoutNewJob; + } + return activityInsertionCosts; + } + + private double getLatestOperationStart(TourActivity act) { + if(state(act) != null){ + return state(act).getLatestOperationStart(); + } + return act.getTheoreticalLatestOperationStartTime(); + } +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionConsideringFixCost.java b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionConsideringFixCost.java new file mode 100644 index 00000000..3660103e --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionConsideringFixCost.java @@ -0,0 +1,116 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.apache.log4j.Logger; + +import algorithms.InsertionData.NoInsertionFound; +import basics.Job; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleImpl.NoVehicle; +import basics.route.VehicleRoute; + + + +final class CalculatesServiceInsertionConsideringFixCost implements JobInsertionCalculator{ + + private static final Logger logger = Logger.getLogger(CalculatesServiceInsertionConsideringFixCost.class); + + private final JobInsertionCalculator standardServiceInsertion; + + private double weight_deltaFixCost = 0.5; + + private double solution_completeness_ratio = 0.5; + + private RouteStates routeStates; + + public CalculatesServiceInsertionConsideringFixCost(final JobInsertionCalculator standardInsertionCalculator, RouteStates routeStates) { + super(); + this.standardServiceInsertion = standardInsertionCalculator; + this.routeStates = routeStates; + logger.info("inialise " + this); + } + + @Override + public InsertionData calculate(final VehicleRoute currentRoute, final Job jobToInsert, final Vehicle newVehicle, double newVehicleDepartureTime, final Driver newDriver, final double bestKnownPrice) { + double relFixCost = getDeltaRelativeFixCost(currentRoute, newVehicle, jobToInsert); + double absFixCost = getDeltaAbsoluteFixCost(currentRoute, newVehicle, jobToInsert); + double deltaFixCost = (1-solution_completeness_ratio)*relFixCost + solution_completeness_ratio*absFixCost; + double fixcost_contribution = weight_deltaFixCost*solution_completeness_ratio*deltaFixCost; + if(fixcost_contribution > bestKnownPrice){ + return InsertionData.noInsertionFound(); + } + InsertionData iData = standardServiceInsertion.calculate(currentRoute, jobToInsert, newVehicle, newVehicleDepartureTime, newDriver, bestKnownPrice); + if(iData instanceof NoInsertionFound){ + return iData; + } + double totalInsertionCost = iData.getInsertionCost() + fixcost_contribution; + InsertionData insertionData = new InsertionData(totalInsertionCost, iData.getPickupInsertionIndex(), iData.getDeliveryInsertionIndex(), newVehicle, newDriver); + insertionData.setVehicleDepartureTime(newVehicleDepartureTime); + return insertionData; + } + + public void setWeightOfFixCost(double weight){ + weight_deltaFixCost = weight; + logger.info("set weightOfFixCostSaving to " + weight); + } + + @Override + public String toString() { + return "[name=calculatesServiceInsertionConsideringFixCost][weightOfFixedCostSavings="+weight_deltaFixCost+"]"; + } + + public void setSolutionCompletenessRatio(double ratio){ + solution_completeness_ratio = ratio; + } + + private double getDeltaAbsoluteFixCost(VehicleRoute route, Vehicle newVehicle, Job job) { + double load = routeStates.getRouteState(route).getLoad() + job.getCapacityDemand(); + double currentFix = 0.0; + if(route.getVehicle() != null){ + if(!(route.getVehicle() instanceof NoVehicle)){ + currentFix += route.getVehicle().getType().vehicleCostParams.fix; + } + } + if(newVehicle.getCapacity() < load){ + return Double.MAX_VALUE; + } + return newVehicle.getType().vehicleCostParams.fix - currentFix; + } + + private double getDeltaRelativeFixCost(VehicleRoute route, Vehicle newVehicle, Job job) { + int currentLoad = routeStates.getRouteState(route).getLoad(); + double load = currentLoad + job.getCapacityDemand(); + double currentRelFix = 0.0; + if(route.getVehicle() != null){ + if(!(route.getVehicle() instanceof NoVehicle)){ + currentRelFix += route.getVehicle().getType().vehicleCostParams.fix*currentLoad/route.getVehicle().getCapacity(); + } + } + if(newVehicle.getCapacity() < load){ + return Double.MAX_VALUE; + } + double relativeFixCost = newVehicle.getType().vehicleCostParams.fix*(load/newVehicle.getCapacity()) - currentRelFix; + return relativeFixCost; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionOnRouteLevel.java b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionOnRouteLevel.java new file mode 100644 index 00000000..366d5885 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionOnRouteLevel.java @@ -0,0 +1,356 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Comparator; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.PriorityQueue; + +import org.apache.log4j.Logger; + +import util.Neighborhood; + +import algorithms.RouteStates.ActivityState; +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.End; +import basics.route.Start; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; +import basics.route.VehicleImpl.NoVehicle; + + + +final class CalculatesServiceInsertionOnRouteLevel implements JobInsertionCalculator{ + + private static final Logger logger = Logger.getLogger(CalculatesServiceInsertionOnRouteLevel.class); + + private final VehicleRoutingTransportCosts transportCosts; + + private final VehicleRoutingActivityCosts activityCosts; + + private AuxilliaryCostCalculator auxilliaryPathCostCalculator; + + private RouteStates routeStates; + + private int nuOfActsForwardLooking = 0; + + private int memorySize = 2; + + private Start start; + + private End end; + + private Neighborhood neighborhood = new Neighborhood() { + + @Override + public boolean areNeighbors(String location1, String location2) { + return true; + } + + }; + + + + public void setNeighborhood(Neighborhood neighborhood) { + this.neighborhood = neighborhood; + logger.info("initialise neighborhood " + neighborhood); + } + + public void setMemorySize(int memorySize) { + this.memorySize = memorySize; + logger.info("set [solutionMemory="+memorySize+"]"); + } + + public CalculatesServiceInsertionOnRouteLevel(VehicleRoutingTransportCosts vehicleRoutingCosts, VehicleRoutingActivityCosts costFunc) { + super(); + this.transportCosts = vehicleRoutingCosts; + this.activityCosts = costFunc; + auxilliaryPathCostCalculator = new AuxilliaryCostCalculator(transportCosts, activityCosts); + logger.info("initialise " + this); + } + + public void setActivityStates(RouteStates actStates){ + this.routeStates = actStates; + } + + public ActivityState state(TourActivity act){ + return routeStates.getState(act); + } + + + void setNuOfActsForwardLooking(int nOfActsForwardLooking) { + this.nuOfActsForwardLooking = nOfActsForwardLooking; + logger.info("set [forwardLooking="+nOfActsForwardLooking+"]"); + } + + @Override + public String toString() { + return "[name=calculatesServiceInsertionOnRouteLevel][solutionMemory="+memorySize+"][forwardLooking="+nuOfActsForwardLooking+"]"; + } + + /** + * Calculates the insertion costs of job i on route level (which is based on the assumption that inserting job i does not only + * have local effects but affects the entire route). + * Calculation is conducted by two steps. In the first step, promising insertion positions are identified by appromiximating their + * marginal insertion cost. In the second step, marginal cost of the best M positions are calculated exactly. + * + * + */ + @Override + public InsertionData calculate(final VehicleRoute currentRoute, final Job jobToInsert, final Vehicle newVehicle, double newVehicleDepartureTime, final Driver newDriver, final double best_known_insertion_costs) { + if(jobToInsert == null) throw new IllegalStateException("job is null. cannot calculate the insertion of a null-job."); + if(newVehicle == null || newVehicle instanceof NoVehicle) throw new IllegalStateException("no vehicle given. set para vehicle!"); + + /** + * map that memorizes the costs with newVehicle, which is a cost-snapshot at tour-activities. + */ + Map activity2costWithNewVehicle = new HashMap(); + + /** + * priority queue that stores insertion-data by insertion-costs in ascending order. + */ + PriorityQueue bestInsertionsQueue = new PriorityQueue(Math.max(2, currentRoute.getTourActivities().getActivities().size()), getComparator()); + + TourActivities tour = currentRoute.getTourActivities(); + double best_insertion_costs = best_known_insertion_costs; + Service service = (Service)jobToInsert; + + /** + * pre-check whether vehicle-capacity of new vehicle is sufficient to load service. + */ + if(routeStates.getRouteState(currentRoute).getLoad() + service.getCapacityDemand() > newVehicle.getCapacity()){ + return InsertionData.noInsertionFound(); + } + + /** + * some inis + */ + TourActivity serviceAct2Insert = routeStates.getActivity(service, true); + int best_insertion_index = InsertionData.NO_INDEX; + + initialiseStartAndEnd(newVehicle, newVehicleDepartureTime); + + TourActivity prevAct = start; + int actIndex = 0; + double sumOf_prevCosts_newVehicle = 0.0; + double prevActDepTime_newVehicle = start.getEndTime(); + + /** + * inserting serviceAct2Insert in route r={0,1,...,i-1,i,j,j+1,...,n(r),n(r)+1} + * i=prevAct + * j=nextAct + * k=serviceAct2Insert + */ + for(TourActivity nextAct : tour.getActivities()){ + if(neighborhood.areNeighbors(serviceAct2Insert.getLocationId(), prevAct.getLocationId()) && neighborhood.areNeighbors(serviceAct2Insert.getLocationId(), nextAct.getLocationId())){ + /** + * builds a path on this route forwardPath={i,k,j,j+1,j+2,...,j+nuOfActsForwardLooking} + */ + List path = new ArrayList(); + path.add(prevAct); path.add(serviceAct2Insert); path.add(nextAct); + if(nuOfActsForwardLooking > 0){ path.addAll(getForwardLookingPath(currentRoute,actIndex)); } + + /** + * calculates the path costs with new vehicle, c(forwardPath,newVehicle). + */ + double forwardPathCost_newVehicle = auxilliaryPathCostCalculator.costOfPath(path, prevActDepTime_newVehicle, newDriver, newVehicle); + + /** + * insertion_cost_approximation = c({0,1,...,i},newVehicle) + c({i,k,j,j+1,j+2,...,j+nuOfActsForwardLooking},newVehicle) - c({0,1,...,i,j,j+1,...,j+nuOfActsForwardLooking},oldVehicle) + */ + double insertion_cost_approximation = sumOf_prevCosts_newVehicle + forwardPathCost_newVehicle - pathCost_oldVehicle(currentRoute,path); + + /** + * memorize it in insertion-queue + */ + if(insertion_cost_approximation < best_known_insertion_costs){ + bestInsertionsQueue.add(new InsertionData(insertion_cost_approximation, InsertionData.NO_INDEX, actIndex, newVehicle, newDriver)); + } + + } + + /** + * calculate transport and activity costs with new vehicle (without inserting k) + */ + double transportCost_prevAct_nextAct_newVehicle = transportCosts.getTransportCost(prevAct.getLocationId(), nextAct.getLocationId(), prevActDepTime_newVehicle, newDriver, newVehicle); + double transportTime_prevAct_nextAct_newVehicle = transportCosts.getTransportTime(prevAct.getLocationId(), nextAct.getLocationId(), prevActDepTime_newVehicle, newDriver, newVehicle); + double arrTime_nextAct_newVehicle = prevActDepTime_newVehicle + transportTime_prevAct_nextAct_newVehicle; + double activityCost_nextAct = activityCosts.getActivityCost(nextAct, arrTime_nextAct_newVehicle, newDriver, newVehicle); + + /** + * memorize transport and activity costs with new vehicle without inserting k + */ + sumOf_prevCosts_newVehicle += transportCost_prevAct_nextAct_newVehicle + activityCost_nextAct; + activity2costWithNewVehicle.put(nextAct, sumOf_prevCosts_newVehicle); + + /** + * departure time at nextAct with new vehicle + */ + double depTime_nextAct_newVehicle = Math.max(arrTime_nextAct_newVehicle, nextAct.getTheoreticalEarliestOperationStartTime()) + nextAct.getOperationTime(); + + /** + * set previous to next + */ + prevAct = nextAct; + prevActDepTime_newVehicle = depTime_nextAct_newVehicle; + + actIndex++; + } + End nextAct = end; + if(neighborhood.areNeighbors(serviceAct2Insert.getLocationId(), prevAct.getLocationId()) && neighborhood.areNeighbors(serviceAct2Insert.getLocationId(), nextAct.getLocationId())){ + + /** + * calculates the path costs with new vehicle, c(forwardPath,newVehicle). + */ + List path = Arrays.asList(prevAct,serviceAct2Insert,end); + double forwardPathCost_newVehicle = auxilliaryPathCostCalculator.costOfPath(path, prevActDepTime_newVehicle, newDriver, newVehicle); + + /** + * insertion_cost_approximation = c({0,1,...,i},newVehicle) + c({i,k,j,j+1,j+2,...,j+nuOfActsForwardLooking},newVehicle) - c({0,1,...,i,j,j+1,...,j+nuOfActsForwardLooking},oldVehicle) + */ + double insertion_cost_approximation = sumOf_prevCosts_newVehicle + forwardPathCost_newVehicle - pathCost_oldVehicle(currentRoute,path); + + /** + * memorize it in insertion-queue + */ + if(insertion_cost_approximation < best_known_insertion_costs){ + bestInsertionsQueue.add(new InsertionData(insertion_cost_approximation,InsertionData.NO_INDEX, actIndex, newVehicle, newDriver)); + } + } + + + /** + * the above calculations approximate insertion costs. now calculate the exact insertion costs for the most promising (according to the approximation) + * insertion positions. + * + */ + + for(int i=0;i wholeTour = new ArrayList(); + wholeTour.add(start); + wholeTour.addAll(currentRoute.getTourActivities().getActivities()); + wholeTour.add(end); + wholeTour.add(data.getDeliveryInsertionIndex()+1, serviceAct2Insert); + + /** + * compute cost-diff of tour with and without new activity --> insertion_costs + */ + double insertion_costs = auxilliaryPathCostCalculator.costOfPath(wholeTour, start.getEndTime(), newDriver, newVehicle) - routeStates.getRouteState(currentRoute).getCosts(); + + /** + * if better than best known, make it the best known + */ + if(insertion_costs < best_insertion_costs){ + best_insertion_index = data.getDeliveryInsertionIndex(); + best_insertion_costs = insertion_costs; + } + } + if(best_insertion_index == InsertionData.NO_INDEX) return InsertionData.noInsertionFound(); + return new InsertionData(best_insertion_costs, InsertionData.NO_INDEX, best_insertion_index, newVehicle, newDriver); + } + + /** + * initialize start and end of tour. + * + * @param newVehicle + * @param newVehicleDepartureTime + */ + private void initialiseStartAndEnd(final Vehicle newVehicle, double newVehicleDepartureTime) { + if(start == null){ + start = Start.newInstance(newVehicle.getLocationId(), newVehicle.getEarliestDeparture(), newVehicle.getLatestArrival()); + start.setEndTime(newVehicleDepartureTime); + } + else{ + start.setLocationId(newVehicle.getLocationId()); + start.setTheoreticalEarliestOperationStartTime(newVehicle.getEarliestDeparture()); + start.setTheoreticalLatestOperationStartTime(newVehicle.getLatestArrival()); + start.setEndTime(newVehicleDepartureTime); + } + + if(end == null){ + end = End.newInstance(newVehicle.getLocationId(), 0.0, newVehicle.getLatestArrival()); + } + else{ + end.setLocationId(newVehicle.getLocationId()); + end.setTheoreticalEarliestOperationStartTime(newVehicleDepartureTime); + end.setTheoreticalLatestOperationStartTime(newVehicle.getLatestArrival()); + } + } + + private double pathCost_oldVehicle(VehicleRoute vehicleRoute, List path) { + TourActivity act = path.get(path.size()-1); + if(act instanceof End){ + return routeStates.getRouteState(vehicleRoute).getCosts(); + } + return state(act).getCurrentCost(); + } + + /** + * returns the path or the partial route r_partial = {j+1,j+2,...,j+nuOfActsForwardLooking} + * + * @param route + * @param actIndex + * @return + */ + private List getForwardLookingPath(VehicleRoute route, int actIndex) { + List forwardLookingPath = new ArrayList(); + int nuOfActsInPath = 0; + int index = actIndex + 1; + while(index < route.getTourActivities().getActivities().size() && nuOfActsInPath < nuOfActsForwardLooking){ + forwardLookingPath.add(route.getTourActivities().getActivities().get(index)); + index++; + nuOfActsInPath++; + } + if(nuOfActsInPath < nuOfActsForwardLooking){ + forwardLookingPath.add(route.getEnd()); + } + return forwardLookingPath; + } + + /** + * creates a comparator to sort insertion-data in insertionQueue in ascending order according insertion costs. + * @return + */ + private Comparator getComparator() { + return new Comparator() { + + @Override + public int compare(InsertionData o1, InsertionData o2) { + if(o1.getInsertionCost() < o2.getInsertionCost()){ + return -1; + } + else { + return 1; + } + + } + }; + } +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionWithTimeScheduling.java b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionWithTimeScheduling.java new file mode 100644 index 00000000..e1ce3079 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatesServiceInsertionWithTimeScheduling.java @@ -0,0 +1,92 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.List; +import java.util.Random; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + +class CalculatesServiceInsertionWithTimeScheduling implements JobInsertionCalculator{ + + private static Logger log = Logger.getLogger(CalculatesServiceInsertionWithTimeScheduling.class); + + private JobInsertionCalculator jic; + + private Random random = new Random(); + + private int nOfDepartureTimes = 3; + + private double timeSlice = 900.0; + + public CalculatesServiceInsertionWithTimeScheduling(JobInsertionCalculator jic, double timeSlice, int neighbors) { + super(); + this.jic = jic; + this.timeSlice = timeSlice; + this.nOfDepartureTimes = neighbors; + log.info("initialise " + this); + } + + @Override + public String toString() { + return "[name=calculatesServiceInsertionWithTimeScheduling][timeSlice="+timeSlice+"][#timeSlice="+nOfDepartureTimes+"]"; + } + + @Override + public InsertionData calculate(VehicleRoute currentRoute, Job jobToInsert, Vehicle newVehicle, double newVehicleDepartureTime, Driver newDriver, double bestKnownScore) { + List vehicleDepartureTimes = new ArrayList(); + double currentStart; + if(currentRoute.getStart() == null){ + currentStart = newVehicleDepartureTime; + } + else currentStart = currentRoute.getStart().getEndTime(); + + vehicleDepartureTimes.add(currentStart); + double earliestDeparture = newVehicle.getEarliestDeparture(); + double latestEnd = newVehicle.getLatestArrival(); + + for(int i=0;i earliestDeparture) vehicleDepartureTimes.add(neighborStartTime_earlier); + double neighborStartTime_later = currentStart + (i+1)*timeSlice; + if(neighborStartTime_later < latestEnd) vehicleDepartureTimes.add(neighborStartTime_later); + } + + InsertionData bestIData = null; + for(Double departureTime : vehicleDepartureTimes){ + InsertionData iData = jic.calculate(currentRoute, jobToInsert, newVehicle, departureTime, newDriver, bestKnownScore); + if(bestIData == null) bestIData = iData; + else if(iData.getInsertionCost() < bestIData.getInsertionCost()){ + iData.setVehicleDepartureTime(departureTime); + bestIData = iData; + } + } +// log.info(bestIData); + return bestIData; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatesVehTypeDepServiceInsertion.java b/jsprit-core/src/main/java/algorithms/CalculatesVehTypeDepServiceInsertion.java new file mode 100644 index 00000000..91bd5ebe --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatesVehTypeDepServiceInsertion.java @@ -0,0 +1,93 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; + +import org.apache.log4j.Logger; + +import algorithms.InsertionData.NoInsertionFound; +import algorithms.VehicleFleetManager.TypeKey; +import basics.Job; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleImpl.NoVehicle; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + + + +final class CalculatesVehTypeDepServiceInsertion implements JobInsertionCalculator{ + + private Logger logger = Logger.getLogger(CalculatesVehTypeDepServiceInsertion.class); + + private final VehicleFleetManager fleetManager; + + private final JobInsertionCalculator insertionCalculator; + + public CalculatesVehTypeDepServiceInsertion(final VehicleFleetManager fleetManager, final JobInsertionCalculator jobInsertionCalc) { + this.fleetManager = fleetManager; + this.insertionCalculator = jobInsertionCalc; + logger.info("inialise " + this); + } + + @Override + public String toString() { + return "[name=vehicleTypeDependentServiceInsertion]"; + } + + public InsertionData calculate(final VehicleRoute currentRoute, final Job jobToInsert, final Vehicle vehicle, double newVehicleDepartureTime, final Driver driver, final double bestKnownCost) { + Vehicle selectedVehicle = currentRoute.getVehicle(); + Driver selectedDriver = currentRoute.getDriver(); + InsertionData bestIData = InsertionData.noInsertionFound(); + double bestKnownCost_ = bestKnownCost; + Collection relevantVehicles = new ArrayList(); + if(!(selectedVehicle instanceof NoVehicle)) relevantVehicles.add(selectedVehicle); + for(TypeKey typeKey : fleetManager.getAvailableVehicleTypes()){ + if(!(currentRoute.getVehicle() instanceof NoVehicle)){ + TypeKey key = makeTypeKey(currentRoute.getVehicle().getType(),currentRoute.getVehicle().getLocationId()); + if(typeKey.equals(key)){ + continue; + } + } + relevantVehicles.add(fleetManager.getEmptyVehicle(typeKey)); + } + for(Vehicle v : relevantVehicles){ + double depTime = v.getEarliestDeparture(); + InsertionData iData = insertionCalculator.calculate(currentRoute, jobToInsert, v, depTime, selectedDriver, bestKnownCost_); + if(iData instanceof NoInsertionFound) { + if(bestIData instanceof NoInsertionFound) bestIData = iData; + continue; + } + if(iData.getInsertionCost() < bestKnownCost_){ + bestIData = iData; + bestKnownCost_ = iData.getInsertionCost(); + } + } + return bestIData; + } + + private TypeKey makeTypeKey(VehicleType type, String locationId) { + return new TypeKey(type,locationId); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/CalculatorBuilder.java b/jsprit-core/src/main/java/algorithms/CalculatorBuilder.java new file mode 100644 index 00000000..ec278889 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CalculatorBuilder.java @@ -0,0 +1,268 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.List; +import java.util.Set; + +import org.apache.commons.configuration.XMLConfiguration; + +import util.NeighborhoodImpl; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.algo.InsertionListener; +import basics.algo.VehicleRoutingAlgorithmListeners.PrioritizedVRAListener; +import basics.algo.VehicleRoutingAlgorithmListeners.Priority; +import basics.costs.VehicleRoutingActivityCosts; + + + +class CalculatorBuilder { + + private static class CalculatorPlusListeners { + + private JobInsertionCalculator calculator; + + public JobInsertionCalculator getCalculator() { + return calculator; + } + + private List algorithmListener = new ArrayList(); + private List insertionListener = new ArrayList(); + + public CalculatorPlusListeners(JobInsertionCalculator calculator) { + super(); + this.calculator = calculator; + } + + public List getAlgorithmListener() { + return algorithmListener; + } + + public List getInsertionListener() { + return insertionListener; + } + } + + private List insertionListeners; + + private List algorithmListeners; + + private VehicleRoutingProblem vrp; + + private RouteStates activityStates; + + private boolean local = true; + + private int forwardLooking = 0; + + private int memory = 1; + + private boolean considerFixedCost = false; + + private double weightOfFixedCost = 0; + + private VehicleFleetManager fleetManager; + + private boolean timeScheduling; + + private double timeSlice; + + private int neighbors; + + /** + * Constructs the builder. + * + *

Some calculators require information from the overall algorithm or the higher-level insertion procedure. Thus listeners inform them. + * These listeners are cached in the according list and can thus be added when its time to add them. + * + * @param insertionListeners + * @param algorithmListeners + */ + public CalculatorBuilder(List insertionListeners, List algorithmListeners) { + super(); + this.insertionListeners = insertionListeners; + this.algorithmListeners = algorithmListeners; + } + + /** + * Sets activityStates. MUST be set. + * + * @param activityStates + * @return + */ + public CalculatorBuilder setActivityStates(RouteStates activityStates){ + this.activityStates = activityStates; + return this; + } + + /** + * Sets routingProblem. MUST be set. + * + * @param vehicleRoutingProblem + * @return + */ + public CalculatorBuilder setVehicleRoutingProblem(VehicleRoutingProblem vehicleRoutingProblem){ + this.vrp = vehicleRoutingProblem; + return this; + } + + /** + * Sets fleetManager. MUST be set. + * + * @param fleetManager + * @return + */ + public CalculatorBuilder setVehicleFleetManager(VehicleFleetManager fleetManager){ + this.fleetManager = fleetManager; + return this; + } + + /** + * Sets a flag to build a calculator based on local calculations. + * + *

Insertion of a job and job-activity is evaluated based on the previous and next activity. + */ + public void setLocalLevel(){ + local = true; + } + + /** + * Sets a flag to build a calculator that evaluates job insertion on route-level. + * + * @param forwardLooking + * @param memory + */ + public void setRouteLevel(int forwardLooking, int memory){ + local = false; + this.forwardLooking = forwardLooking; + this.memory = memory; + } + + /** + * Sets a flag to consider also fixed-cost when evaluating the insertion of a job. The weight of the fixed-cost can be determined by setting + * weightofFixedCosts. + * + * @param weightOfFixedCosts + */ + public void considerFixedCosts(double weightOfFixedCosts){ + considerFixedCost = true; + this.weightOfFixedCost = weightOfFixedCosts; + } + + public void experimentalTimeScheduler(double timeSlice, int neighbors){ + timeScheduling = true; + this.timeSlice = timeSlice; + this.neighbors = neighbors; + } + + /** + * Builds the jobInsertionCalculator. + * + * @return jobInsertionCalculator. + * @throws IllegalStateException if vrp == null or activityStates == null or fleetManager == null. + */ + public JobInsertionCalculator build(){ + if(vrp == null) throw new IllegalStateException("vehicle-routing-problem is null, but it must be set (this.setVehicleRoutingProblem(vrp))"); + if(activityStates == null) throw new IllegalStateException("activity states is null, but is must be set (this.setActivityStates(states))"); + if(fleetManager == null) throw new IllegalStateException("fleetManager is null, but it must be set (this.setVehicleFleetManager(fleetManager))"); + JobInsertionCalculator baseCalculator = null; + CalculatorPlusListeners standardLocal = null; + if(local){ + standardLocal = createStandardLocal(vrp, activityStates); + } + else{ + standardLocal = createStandardRoute(vrp, activityStates,forwardLooking,memory); + } + baseCalculator = standardLocal.getCalculator(); + addAlgorithmListeners(standardLocal.getAlgorithmListener()); + addInsertionListeners(standardLocal.getInsertionListener()); + if(considerFixedCost){ + CalculatorPlusListeners withFixed = createCalculatorConsideringFixedCosts(vrp, baseCalculator, activityStates, weightOfFixedCost); + baseCalculator = withFixed.getCalculator(); + addAlgorithmListeners(withFixed.getAlgorithmListener()); + addInsertionListeners(withFixed.getInsertionListener()); + } + if(timeScheduling){ + baseCalculator = new CalculatesServiceInsertionWithTimeScheduling(baseCalculator,timeSlice,neighbors); + } + return createFinalInsertion(fleetManager, baseCalculator, activityStates); + } + + private void addInsertionListeners(List list) { + for(InsertionListener iL : list){ + insertionListeners.add(iL); + } + } + + private void addAlgorithmListeners(List list) { + for(PrioritizedVRAListener aL : list){ + algorithmListeners.add(aL); + } + } + + private CalculatorPlusListeners createStandardLocal(VehicleRoutingProblem vrp, RouteStates activityStates){ + JobInsertionCalculator standardServiceInsertion = new CalculatesServiceInsertion(vrp.getTransportCosts(), vrp.getActivityCosts()); + ((CalculatesServiceInsertion) standardServiceInsertion).setActivityStates(activityStates); + ((CalculatesServiceInsertion) standardServiceInsertion).setNeighborhood(vrp.getNeighborhood()); + CalculatorPlusListeners calcPlusListeners = new CalculatorPlusListeners(standardServiceInsertion); + + return calcPlusListeners; + } + + private CalculatorPlusListeners createCalculatorConsideringFixedCosts(VehicleRoutingProblem vrp, JobInsertionCalculator baseCalculator, RouteStates activityStates, double weightOfFixedCosts){ + final CalculatesServiceInsertionConsideringFixCost withFixCost = new CalculatesServiceInsertionConsideringFixCost(baseCalculator, activityStates); + withFixCost.setWeightOfFixCost(weightOfFixedCosts); + CalculatorPlusListeners calcPlusListeners = new CalculatorPlusListeners(withFixCost); + calcPlusListeners.getInsertionListener().add(new ConfigureFixCostCalculator(vrp, withFixCost)); + return calcPlusListeners; + } + + private CalculatorPlusListeners createStandardRoute(VehicleRoutingProblem vrp, RouteStates activityStates, int forwardLooking, int solutionMemory){ + int after = forwardLooking; + JobInsertionCalculator jobInsertionCalculator = new CalculatesServiceInsertionOnRouteLevel(vrp.getTransportCosts(), vrp.getActivityCosts()); + ((CalculatesServiceInsertionOnRouteLevel)jobInsertionCalculator).setNuOfActsForwardLooking(after); + ((CalculatesServiceInsertionOnRouteLevel)jobInsertionCalculator).setMemorySize(solutionMemory); + ((CalculatesServiceInsertionOnRouteLevel)jobInsertionCalculator).setNeighborhood(vrp.getNeighborhood()); + ((CalculatesServiceInsertionOnRouteLevel) jobInsertionCalculator).setActivityStates(activityStates); + CalculatorPlusListeners calcPlusListener = new CalculatorPlusListeners(jobInsertionCalculator); + return calcPlusListener; + } + + private JobInsertionCalculator createFinalInsertion(VehicleFleetManager fleetManager, JobInsertionCalculator baseCalc, RouteStates routeStates){ + return new CalculatesVehTypeDepServiceInsertion(fleetManager, baseCalc); + } + +} + + + + + + + + + + + + diff --git a/jsprit-core/src/main/java/algorithms/ConfigureFixCostCalculator.java b/jsprit-core/src/main/java/algorithms/ConfigureFixCostCalculator.java new file mode 100644 index 00000000..179164da --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/ConfigureFixCostCalculator.java @@ -0,0 +1,70 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + + +import java.util.Collection; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.algo.InsertionStartsListener; +import basics.algo.JobInsertedListener; +import basics.route.VehicleRoute; + + + + + +final class ConfigureFixCostCalculator implements InsertionStartsListener, JobInsertedListener{ + + private static Logger log = Logger.getLogger(ConfigureFixCostCalculator.class); + + VehicleRoutingProblem vrp; + + CalculatesServiceInsertionConsideringFixCost calcConsideringFix; + + public ConfigureFixCostCalculator(VehicleRoutingProblem vrp, CalculatesServiceInsertionConsideringFixCost calcConsideringFix) { + super(); + this.vrp = vrp; + this.calcConsideringFix = calcConsideringFix; + } + + @Override + public String toString() { + return "[name=configureFixCostCalculator]"; + } + + @Override + public void informInsertionStarts(Collection routes, int nOfJobs2Recreate) { + double completenessRatio = (1-((double)nOfJobs2Recreate/(double)vrp.getJobs().values().size())); + calcConsideringFix.setSolutionCompletenessRatio(completenessRatio); +// log.debug("initialise completenessRatio to " + completenessRatio); + } + + @Override + public void informJobInserted(int nOfJobsStill2Recreate, Job job2insert, VehicleRoute insertedIn) { + double completenessRatio = (1-((double)nOfJobsStill2Recreate/(double)vrp.getJobs().values().size())); + calcConsideringFix.setSolutionCompletenessRatio(completenessRatio); +// log.debug("set completenessRatio to " + completenessRatio); + } +} diff --git a/jsprit-core/src/main/java/algorithms/CreateInitialSolution.java b/jsprit-core/src/main/java/algorithms/CreateInitialSolution.java new file mode 100644 index 00000000..dcaee915 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/CreateInitialSolution.java @@ -0,0 +1,95 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +/* *********************************************************************** * + * project: org.matsim.* + * IniSolution.java + * * + * *********************************************************************** * + * * + * copyright : (C) 2011 by the members listed in the COPYING, * + * LICENSE and WARRANTY file. * + * email : info at matsim dot org * + * * + * *********************************************************************** * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * See also COPYING, LICENSE and WARRANTY file * + * * + * *********************************************************************** */ + +package algorithms; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.route.DriverImpl; +import basics.route.TourActivities; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + + +final class CreateInitialSolution implements InitialSolutionFactory { + + private static final Logger logger = Logger.getLogger(CreateInitialSolution.class); + + private final AbstractInsertionStrategy insertion; + + private boolean generateAsMuchAsRoutesAsVehiclesExist = false; + + public void setGenerateAsMuchAsRoutesAsVehiclesExist(boolean generateAsMuchAsRoutesAsVehiclesExist) { + this.generateAsMuchAsRoutesAsVehiclesExist = generateAsMuchAsRoutesAsVehiclesExist; + } + + public CreateInitialSolution(AbstractInsertionStrategy insertion) { + super(); + this.insertion = insertion; + } + + @Override + public VehicleRoutingProblemSolution createInitialSolution(final VehicleRoutingProblem vrp) { + logger.info("create initial solution."); + List vehicleRoutes = new ArrayList(); + if(generateAsMuchAsRoutesAsVehiclesExist){ + for(Vehicle vehicle : vrp.getVehicles()){ + vehicleRoutes.add(VehicleRoute.newInstance(TourActivities.emptyTour(), DriverImpl.noDriver(), vehicle)); + } + } + insertion.run(vehicleRoutes, getUnassignedJobs(vrp), Double.MAX_VALUE); + double totalCost = getTotalCost(vehicleRoutes); + logger.info("creation done"); + return new VehicleRoutingProblemSolution(vehicleRoutes, totalCost); + } + + private double getTotalCost(List serviceProviders) { + double c = 0.0; + for(VehicleRoute a : serviceProviders){ + c += a.getCost(); + } + return c; + } + + private List getUnassignedJobs(VehicleRoutingProblem vrp) { + List jobs = new ArrayList(vrp.getJobs().values()); + return jobs; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/FindCheaperVehicle.java b/jsprit-core/src/main/java/algorithms/FindCheaperVehicle.java new file mode 100644 index 00000000..9a19f579 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/FindCheaperVehicle.java @@ -0,0 +1,56 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import basics.algo.InsertionStartsListener; +import basics.route.VehicleRoute; + +class FindCheaperVehicle implements InsertionStartsListener{ + + FindCheaperVehicleAlgo findCheaperVehicle; + + public FindCheaperVehicle(FindCheaperVehicleAlgo findCheaperVehicle) { + super(); + this.findCheaperVehicle = findCheaperVehicle; + } + + @Override + public void informInsertionStarts(Collection vehicleRoutes, int nOfJobs2Recreate) { + List newRoutes = new ArrayList(); + for(VehicleRoute route : vehicleRoutes){ + if(route.isEmpty()) continue; + VehicleRoute cheaperRoute = findCheaperVehicle.runAndGetVehicleRoute(route); + newRoutes.add(cheaperRoute); + } + vehicleRoutes.clear(); + vehicleRoutes.addAll(newRoutes); + } + + @Override + public String toString() { + return "[name=findCheaperVehicle]"; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/FindCheaperVehicleAlgo.java b/jsprit-core/src/main/java/algorithms/FindCheaperVehicleAlgo.java new file mode 100644 index 00000000..ca3415ef --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/FindCheaperVehicleAlgo.java @@ -0,0 +1,115 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import org.apache.log4j.Logger; + +import algorithms.VehicleFleetManager.TypeKey; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; +import basics.route.VehicleImpl.NoVehicle; + + + +final class FindCheaperVehicleAlgo { + + private static Logger log = Logger.getLogger(FindCheaperVehicleAlgo.class); + + private VehicleFleetManager fleetManager; + + private VehicleRouteUpdater tourStateCalculator; + + private AuxilliaryCostCalculator auxilliaryCostCalculator; + + private double weightFixCosts = 1.0; + + private RouteStates states; + + public void setWeightFixCosts(double weightFixCosts) { + this.weightFixCosts = weightFixCosts; + } + + public void setStates(RouteStates states) { + this.states = states; + } + + public FindCheaperVehicleAlgo(VehicleFleetManager fleetManager, VehicleRouteUpdater tourStateCalculator, AuxilliaryCostCalculator auxilliaryCostCalculator) { + super(); + this.fleetManager = fleetManager; + this.tourStateCalculator = tourStateCalculator; + this.auxilliaryCostCalculator = auxilliaryCostCalculator; + } + + + public VehicleRoute runAndGetVehicleRoute(VehicleRoute vehicleRoute) { + if(vehicleRoute.getVehicle() instanceof NoVehicle){ + return vehicleRoute; + } + if(vehicleRoute.getTourActivities() == null || vehicleRoute.getVehicle() == null){ + return vehicleRoute; + } + Collection availableVehicleTypes = fleetManager.getAvailableVehicleTypes(new TypeKey(vehicleRoute.getVehicle().getType(),vehicleRoute.getVehicle().getLocationId())); + double bestSaving = 0.0; + Vehicle bestVehicle = null; + List path = new ArrayList(); + path.add(vehicleRoute.getStart()); + path.addAll(vehicleRoute.getTourActivities().getActivities()); + path.add(vehicleRoute.getEnd()); + + for(TypeKey vehicleType : availableVehicleTypes){ + Vehicle vehicle = fleetManager.getEmptyVehicle(vehicleType); + if(vehicle.getType().typeId.equals(vehicleRoute.getVehicle().getType().typeId)){ + continue; + } + if(states.getRouteState(vehicleRoute).getLoad() <= vehicle.getCapacity()){ + double fixCostSaving = vehicleRoute.getVehicle().getType().vehicleCostParams.fix - vehicle.getType().vehicleCostParams.fix; + double departureTime = vehicleRoute.getStart().getEndTime(); + double newCost = auxilliaryCostCalculator.costOfPath(path, departureTime, vehicleRoute.getDriver(), vehicle); + double varCostSaving = states.getRouteState(vehicleRoute).getCosts() - newCost; + double totalCostSaving = varCostSaving + weightFixCosts*fixCostSaving; + if(totalCostSaving > bestSaving){ + bestSaving = totalCostSaving; + bestVehicle = vehicle; + } + } + } + if(bestVehicle != null){ + try{ + fleetManager.unlock(vehicleRoute.getVehicle()); + fleetManager.lock(bestVehicle); + } + catch(IllegalStateException e){ + throw new IllegalStateException(e); + } + TourActivities newTour = TourActivities.copyOf(vehicleRoute.getTourActivities()); + tourStateCalculator.updateRoute(vehicleRoute); + return VehicleRoute.newInstance(newTour,vehicleRoute.getDriver(),bestVehicle); + } + return vehicleRoute; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/GendreauPostOpt.java b/jsprit-core/src/main/java/algorithms/GendreauPostOpt.java new file mode 100644 index 00000000..c7560cee --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/GendreauPostOpt.java @@ -0,0 +1,207 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.List; +import java.util.Random; +import java.util.Set; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.SearchStrategyModule; +import basics.algo.SearchStrategyModuleListener; +import basics.route.TourActivity; +import basics.route.VehicleRoute; +import basics.route.TourActivity.JobActivity; + +import util.RandomNumberGeneration; + +final class GendreauPostOpt implements SearchStrategyModule{ + + private final static Logger log = Logger.getLogger(GendreauPostOpt.class); + + private final static String NAME = "gendreauPostOpt"; + + private final RuinStrategy ruin; + + private final VehicleRoutingProblem vrp; + + private final AbstractInsertionStrategy insertionStrategy; + + private final RouteAlgorithm routeAlgorithm; + + private VehicleFleetManager fleetManager; + + private Random random = RandomNumberGeneration.getRandom(); + + private int nOfIterations = 10; + + private double shareOfJobsToRuin = 0.15; + + public void setShareOfJobsToRuin(double shareOfJobsToRuin) { + this.shareOfJobsToRuin = shareOfJobsToRuin; + } + + public GendreauPostOpt(VehicleRoutingProblem vrp, RuinStrategy ruin, AbstractInsertionStrategy insertionStrategy) { + super(); + this.routeAlgorithm = insertionStrategy.getRouteAlgorithm(); + this.ruin = ruin; + this.vrp = vrp; + this.insertionStrategy = insertionStrategy; + } + + @Override + public String toString() { + return "[name=gendreauPostOpt][iterations="+nOfIterations+"][share2ruin="+shareOfJobsToRuin+"]"; + } + + public void setRandom(Random random) { + this.random = random; + } + + + public void setNuOfIterations(int nOfIterations) { + this.nOfIterations = nOfIterations; + } + + public void setFleetManager(VehicleFleetManager vehicleFleetManager) { + this.fleetManager = vehicleFleetManager; + + } + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { +// log.info("run gendreau postopt"); + VehicleRoutingProblemSolution bestSolution = vrpSolution; + int itersWithoutImprovement = 0; + + for(int i=0;i copiedRoutes = copyRoutes(bestSolution.getRoutes()); + iniFleet(copiedRoutes); + + VehicleRoute route2split = pickRouteThatHasAtLeastTwoJobs(copiedRoutes); + if(route2split == null) continue; + List jobsInRoute = getJobs(route2split); + Set unassignedJobs = new HashSet(); + unassignedJobs.addAll(jobsInRoute); + copiedRoutes.remove(route2split); + + Collections.shuffle(jobsInRoute,random); + Job targetJob = jobsInRoute.get(0); + int nOfJobs2BeRemovedAdditionally = (int) (shareOfJobsToRuin*(double)vrp.getJobs().size()); + Collection unassignedJobsList = ruin.ruin(copiedRoutes, targetJob, nOfJobs2BeRemovedAdditionally); + unassignedJobs.addAll(unassignedJobsList); + + VehicleRoute emptyRoute1 = VehicleRoute.emptyRoute(); + copiedRoutes.add(emptyRoute1); + routeAlgorithm.insertJob(targetJob, routeAlgorithm.calculateBestInsertion(emptyRoute1, targetJob, Double.MAX_VALUE), emptyRoute1); + unassignedJobs.remove(targetJob); + + VehicleRoute emptyRoute2 = VehicleRoute.emptyRoute(); + copiedRoutes.add(emptyRoute2); + Job job2 = jobsInRoute.get(1); + routeAlgorithm.insertJob(job2, routeAlgorithm.calculateBestInsertion(emptyRoute2, job2, Double.MAX_VALUE), emptyRoute2); + unassignedJobs.remove(job2); + + insertionStrategy.run(copiedRoutes, unassignedJobs, Double.MAX_VALUE); + double cost = getCost(copiedRoutes); + + if(cost < bestSolution.getCost()){ +// log.info("BING - new: " + cost + " old: " + bestSolution.getCost()); + bestSolution = new VehicleRoutingProblemSolution(copiedRoutes, cost); + itersWithoutImprovement=0; + } + else{ + itersWithoutImprovement++; + if(itersWithoutImprovement > 200){ +// log.info("BREAK i="+i); + break; + } + } + } + return bestSolution; + } + + private List copyRoutes(Collection routes) { + List routeList = new ArrayList(); + for(VehicleRoute r : routes){ + routeList.add(VehicleRoute.copyOf(r)); + } + return routeList; + } + + private void iniFleet(Collection routes) { + fleetManager.unlockAll(); + for(VehicleRoute route : routes){ + if(!route.isEmpty()){ + fleetManager.lock(route.getVehicle()); + } + } + } + + private double getCost(Collection routes) { + double c = 0.0; + for(VehicleRoute r : routes){ + c+=r.getCost(); + } + return c; + } + + private List getJobs(VehicleRoute route2split) { + Set jobs = new HashSet(); + for(TourActivity act : route2split.getTourActivities().getActivities()){ + if(act instanceof JobActivity){ + jobs.add(((JobActivity) act).getJob()); + } + } + return new ArrayList(jobs); + } + + private VehicleRoute pickRouteThatHasAtLeastTwoJobs(Collection routeList) { + List routes = new ArrayList(); + for(VehicleRoute r : routeList){ + if(getJobs(r).size() > 1){ + routes.add(r); + } + } + if(routes.isEmpty()) return null; + Collections.shuffle(routes,random); + return routes.get(0); + } + + @Override + public String getName() { + return NAME; + } + + @Override + public void addModuleListener(SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } +} diff --git a/jsprit-core/src/main/java/algorithms/InfiniteVehicles.java b/jsprit-core/src/main/java/algorithms/InfiniteVehicles.java new file mode 100644 index 00000000..b214854d --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InfiniteVehicles.java @@ -0,0 +1,115 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import org.apache.log4j.Logger; + +import basics.route.Vehicle; +import basics.route.VehicleImpl.VehicleType; + +class InfiniteVehicles implements VehicleFleetManager{ + + static class TypeKeyComparator implements Comparator{ + + @Override + public int compare(TypeKey k1, TypeKey k2) { + double k1_fix = k1.type.getVehicleCostParams().fix; + double k2_fix = k2.type.getVehicleCostParams().fix; + return (int)(k1_fix - k2_fix); + } + + } + + private static Logger logger = Logger.getLogger(InfiniteVehicles.class); + + private Map types = new HashMap(); + + private List sortedTypes = new ArrayList(); + + public InfiniteVehicles(Collection vehicles){ + extractTypes(vehicles); + logger.info("initialise " + this); + } + + @Override + public String toString() { + return "[name=infiniteVehicle]"; + } + + private void extractTypes(Collection vehicles) { + for(Vehicle v : vehicles){ + TypeKey typeKey = new TypeKey(v.getType(),v.getLocationId()); + types.put(typeKey,v); + sortedTypes.add(typeKey); + + } + Collections.sort(sortedTypes, new TypeKeyComparator()); + } + + + @Override + public Vehicle getEmptyVehicle(TypeKey typeId) { + return types.get(typeId); + } + + @Override + public Collection getAvailableVehicleTypes() { + return sortedTypes; + } + + @Override + public void lock(Vehicle vehicle) { + + } + + @Override + public void unlock(Vehicle vehicle) { + + } + + @Override + public Collection getAvailableVehicleTypes(TypeKey withoutThisType) { + Set typeSet = new HashSet(types.keySet()); + typeSet.remove(withoutThisType); + return typeSet; + } + + @Override + public boolean isLocked(Vehicle vehicle) { + return false; + } + + @Override + public void unlockAll() { + + } + +} diff --git a/jsprit-core/src/main/java/algorithms/InitialSolutionFactory.java b/jsprit-core/src/main/java/algorithms/InitialSolutionFactory.java new file mode 100644 index 00000000..ed1a1d8c --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InitialSolutionFactory.java @@ -0,0 +1,24 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +interface InitialSolutionFactory { + + public VehicleRoutingProblemSolution createInitialSolution(VehicleRoutingProblem vrp); + +} diff --git a/jsprit-core/src/main/java/algorithms/InsertionData.java b/jsprit-core/src/main/java/algorithms/InsertionData.java new file mode 100644 index 00000000..ddd6507f --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InsertionData.java @@ -0,0 +1,107 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.route.Driver; +import basics.route.Vehicle; + + + +class InsertionData { + + static class NoInsertionFound extends InsertionData{ + + public NoInsertionFound() { + super(Double.MAX_VALUE, NO_INDEX, NO_INDEX, null, null); + } + + } + + private static InsertionData noInsertion = new NoInsertionFound(); + + public static InsertionData noInsertionFound(){ + return noInsertion; + } + + static int NO_INDEX = -1; + + private final double insertionCost; + + private final int pickupInsertionIndex; + + private final int deliveryInsertionIndex; + + private final Vehicle selectedVehicle; + + private final Driver selectedDriver; + + private double departureTime; + + public InsertionData(double insertionCost, int pickupInsertionIndex, int deliveryInsertionIndex, Vehicle vehicle, Driver driver){ + this.insertionCost = insertionCost; + this.pickupInsertionIndex = pickupInsertionIndex; + this.deliveryInsertionIndex = deliveryInsertionIndex; + this.selectedVehicle = vehicle; + this.selectedDriver = driver; + } + + @Override + public String toString() { + return "[iCost="+insertionCost+"][iIndex="+deliveryInsertionIndex+"][depTime="+departureTime+"][vehicle="+selectedVehicle+"][driver="+selectedDriver+"]"; + } + + public int getDeliveryInsertionIndex(){ + return deliveryInsertionIndex; + } + + public int getPickupInsertionIndex(){ + return pickupInsertionIndex; + } + + public double getInsertionCost() { + return insertionCost; + } + + public Vehicle getSelectedVehicle() { + return selectedVehicle; + } + + public Driver getSelectedDriver(){ + return selectedDriver; + } + + /** + * @return the departureTime + */ + public double getVehicleDepartureTime() { + return departureTime; + } + + /** + * @param departureTime the departureTime to set + */ + public void setVehicleDepartureTime(double departureTime) { + this.departureTime = departureTime; + } + + + +} diff --git a/jsprit-core/src/main/java/algorithms/InsertionFactory.java b/jsprit-core/src/main/java/algorithms/InsertionFactory.java new file mode 100644 index 00000000..5de8a1f4 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InsertionFactory.java @@ -0,0 +1,132 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.commons.configuration.HierarchicalConfiguration; +import org.apache.commons.configuration.XMLConfiguration; +import org.apache.log4j.Logger; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.algo.InsertionListener; +import basics.algo.VehicleRoutingAlgorithmListeners.PrioritizedVRAListener; + +class InsertionFactory { + + private static Logger log = Logger.getLogger(InsertionFactory.class); + + public static AbstractInsertionStrategy createInsertion(VehicleRoutingProblem vrp, HierarchicalConfiguration config, + VehicleFleetManager vehicleFleetManager, RouteStates activityStates, List algorithmListeners){ + + if(config.containsKey("[@name]")){ + String insertionName = config.getString("[@name]"); + if(!insertionName.equals("bestInsertion") && !insertionName.equals("regretInsertion")){ + new IllegalStateException(insertionName + " is not supported. use either \"bestInsertion\" or \"regretInsertion\""); + } + AbstractInsertionStrategy insertionStrategy = null; + List insertionListeners = new ArrayList(); + List algoListeners = new ArrayList(); + + CalculatorBuilder calcBuilder = new CalculatorBuilder(insertionListeners, algorithmListeners); + calcBuilder.setActivityStates(activityStates); + calcBuilder.setVehicleRoutingProblem(vrp); + calcBuilder.setVehicleFleetManager(vehicleFleetManager); + + if(config.containsKey("level")){ + String level = config.getString("level"); + if(level.equals("local")){ + calcBuilder.setLocalLevel(); + } + else if(level.equals("route")){ + int forwardLooking = 0; + int memory = 1; + String forward = config.getString("level[@forwardLooking]"); + String mem = config.getString("level[@memory]"); + if(forward != null) forwardLooking = Integer.parseInt(forward); + else log.warn("parameter route[@forwardLooking] is missing. by default it is 0 which equals to local level"); + if(mem != null) memory = Integer.parseInt(mem); + else log.warn("parameter route[@memory] is missing. by default it is 1"); + calcBuilder.setRouteLevel(forwardLooking, memory); + } + else throw new IllegalStateException("level " + level + " is not known. currently it only knows \"local\" or \"route\""); + } + else calcBuilder.setLocalLevel(); + + if(config.containsKey("considerFixedCosts") || config.containsKey("considerFixedCost")){ + String val = config.getString("considerFixedCosts"); + if(val == null) val = config.getString("considerFixedCost"); + if(val.equals("true")){ + double fixedCostWeight = 0.5; + String weight = config.getString("considerFixedCosts[@weight]"); + if(weight == null) weight = config.getString("considerFixedCost[@weight]"); + if(weight != null) fixedCostWeight = Double.parseDouble(weight); + else log.warn("parameter considerFixedCosts[@weight] is missing. by default, it is 0.5."); + calcBuilder.considerFixedCosts(fixedCostWeight); + } + } + String timeSliceString = config.getString("experimental[@timeSlice]"); + String neighbors = config.getString("experimental[@neighboringSlices]"); + if(timeSliceString != null && neighbors != null){ + calcBuilder.experimentalTimeScheduler(Double.parseDouble(timeSliceString),Integer.parseInt(neighbors)); + } + + JobInsertionCalculator jic = calcBuilder.build(); + TourStateUpdater tourStateCalculator = new TourStateUpdater(activityStates, vrp.getTransportCosts(), vrp.getActivityCosts()); + RouteAlgorithm routeAlgorithm = RouteAlgorithmImpl.newInstance(jic, tourStateCalculator); + routeAlgorithm.getListeners().add(new VehicleSwitched(vehicleFleetManager)); + ((RouteAlgorithmImpl) routeAlgorithm).setActivityStates(activityStates); + + if(insertionName.equals("bestInsertion")){ + insertionStrategy = BestInsertion.newInstance(routeAlgorithm); + } + else if(insertionName.equals("regretInsertion")){ + insertionStrategy = RegretInsertion.newInstance(routeAlgorithm); + } +// else if(insertionName.equals("concurrentBestInsertion")){ +// String processorsString = config.getString("[@processors]"); +// int processors = 1; +// if(processorsString != null) processors = Integer.parseInt(processorsString); +//// BestInsertionConcurrent.newInstance(routeAlgorithm,) +// +// +// } + + insertionStrategy.addListener(new RemoveEmptyVehicles()); + insertionStrategy.addListener(new ResetAndIniFleetManager(vehicleFleetManager)); + insertionStrategy.addAllListener(insertionListeners); +// insertionStrategy.addListener(new FindCheaperVehicle( +// new FindCheaperVehicleAlgoNew(vehicleFleetManager, tourStateCalculator, auxCalculator))); + + algorithmListeners.addAll(algoListeners); + + return insertionStrategy; + } + else throw new IllegalStateException("cannot create insertionStrategy, since it has no name."); + } + + +} + + + diff --git a/jsprit-core/src/main/java/algorithms/InsertionStrategy.java b/jsprit-core/src/main/java/algorithms/InsertionStrategy.java new file mode 100644 index 00000000..7c56995b --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InsertionStrategy.java @@ -0,0 +1,66 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; + +import basics.Job; +import basics.route.VehicleRoute; + + + + +/** + * + * @author stefan schroeder + * + */ + +interface InsertionStrategy { + + class Insertion { + + private final VehicleRoute route; + + private final InsertionData insertionData; + + public Insertion(VehicleRoute vehicleRoute, InsertionData insertionData) { + super(); + this.route = vehicleRoute; + this.insertionData = insertionData; + } + + public VehicleRoute getRoute() { + return route; + } + + public InsertionData getInsertionData() { + return insertionData; + } + + } + + + + + + /** + * Assigns the unassigned jobs to service-providers + * + * @param vehicleRoutes + * @param unassignedJobs + * @param result2beat + */ + public void run(Collection vehicleRoutes, Collection unassignedJobs, double result2beat); + +} diff --git a/jsprit-core/src/main/java/algorithms/InsertionStrategyFactory.java b/jsprit-core/src/main/java/algorithms/InsertionStrategyFactory.java new file mode 100644 index 00000000..856512b6 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/InsertionStrategyFactory.java @@ -0,0 +1,29 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.VehicleRoutingProblem; + +interface InsertionStrategyFactory { + + public InsertionStrategy createStrategy(VehicleRoutingProblem vrp); + +} diff --git a/jsprit-core/src/main/java/algorithms/JobDistance.java b/jsprit-core/src/main/java/algorithms/JobDistance.java new file mode 100644 index 00000000..82464989 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobDistance.java @@ -0,0 +1,23 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; + + + +interface JobDistance { + + public double calculateDistance(Job i, Job j); + +} diff --git a/jsprit-core/src/main/java/algorithms/JobDistanceAvgCosts.java b/jsprit-core/src/main/java/algorithms/JobDistanceAvgCosts.java new file mode 100644 index 00000000..74c742e8 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobDistanceAvgCosts.java @@ -0,0 +1,66 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingTransportCosts; + + + +class JobDistanceAvgCosts implements JobDistance { + + private VehicleRoutingTransportCosts costs; + + public JobDistanceAvgCosts(VehicleRoutingTransportCosts costs) { + super(); + this.costs = costs; + + } + + @Override + public double calculateDistance(Job i, Job j) { + double avgCost = 0.0; +// if (i instanceof Shipment && j instanceof Shipment) { +// if (i.equals(j)) { +// avgCost = 0.0; +// } else { +// Shipment s_i = (Shipment) i; +// Shipment s_j = (Shipment) j; +// double cost_i1_j1 = calcDist(s_i.getFromId(), s_j.getFromId()); +// double cost_i1_j2 = calcDist(s_i.getFromId(), s_j.getToId()); +// double cost_i2_j1 = calcDist(s_i.getToId(), s_j.getFromId()); +// double cost_i2_j2 = calcDist(s_i.getToId(), s_j.getToId()); +// avgCost = (cost_i1_j1 + cost_i1_j2 + cost_i2_j1 + cost_i2_j2) / 4; +// } +// } else + if (i instanceof Service && j instanceof Service) { + if (i.equals(j)) { + avgCost = 0.0; + } else { + Service s_i = (Service) i; + Service s_j = (Service) j; + avgCost = calcDist(s_i.getLocationId(), s_j.getLocationId()); + } + } else { + throw new UnsupportedOperationException( + "currently, this class just works with shipments and services."); + } + return avgCost; + } + + private double calcDist(String from, String to) { + return costs.getTransportCost(from, to, 0.0, null, null); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/JobDistanceBeeline.java b/jsprit-core/src/main/java/algorithms/JobDistanceBeeline.java new file mode 100644 index 00000000..b0fe0f5c --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobDistanceBeeline.java @@ -0,0 +1,66 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import util.CrowFlyCosts; +import util.Locations; +import basics.Job; +import basics.Service; + + + +class JobDistanceBeeline implements JobDistance { + + private Locations locations; + + public JobDistanceBeeline(Locations locations) { + super(); + this.locations = locations; + } + + @Override + public double calculateDistance(Job i, Job j) { + double avgCost = 0.0; +// if (i instanceof Shipment && j instanceof Shipment) { +// if (i.equals(j)) { +// avgCost = 0.0; +// } else { +// Shipment s_i = (Shipment) i; +// Shipment s_j = (Shipment) j; +// double cost_i1_j1 = calcDist(s_i.getFromId(), s_j.getFromId()); +// double cost_i1_j2 = calcDist(s_i.getFromId(), s_j.getToId()); +// double cost_i2_j1 = calcDist(s_i.getToId(), s_j.getFromId()); +// double cost_i2_j2 = calcDist(s_i.getToId(), s_j.getToId()); +// avgCost = (cost_i1_j1 + cost_i1_j2 + cost_i2_j1 + cost_i2_j2) / 4; +// } +// } else + if (i instanceof Service && j instanceof Service) { + if (i.equals(j)) { + avgCost = 0.0; + } else { + Service s_i = (Service) i; + Service s_j = (Service) j; + avgCost = calcDist(s_i.getLocationId(), s_j.getLocationId()); + } + } else { + throw new UnsupportedOperationException( + "currently, this class just works with shipments and services."); + } + return avgCost; + } + + private double calcDist(String from, String to) { + return new CrowFlyCosts(locations).getTransportCost(from, to, 0.0,null, null); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/JobInsertionCalculator.java b/jsprit-core/src/main/java/algorithms/JobInsertionCalculator.java new file mode 100644 index 00000000..88b8b7fd --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobInsertionCalculator.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + + interface JobInsertionCalculator { + + public InsertionData calculate(VehicleRoute currentRoute, Job jobToInsert, Vehicle newVehicle, double newVehicleDepartureTime, Driver newDriver, double bestKnownScore); + +} diff --git a/jsprit-core/src/main/java/algorithms/JobObserver.java b/jsprit-core/src/main/java/algorithms/JobObserver.java new file mode 100644 index 00000000..43641b04 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobObserver.java @@ -0,0 +1,156 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + + +import java.io.BufferedWriter; +import java.io.FileWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Collection; + +import algorithms.RouteStates.ActivityState; +import basics.algo.AlgorithmEndsListener; +import basics.algo.JobInsertedListener; +import basics.route.TourActivity; +import basics.route.VehicleRoute; +import basics.route.TourActivity.JobActivity; +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + +class JobObserver implements JobInsertedListener, BeforeJobInsertionListener, AlgorithmEndsListener{ + + private static class Info { + double depTime; + double tourSize; + double insertionIndex; + double error; + public Info(double depTime, double tourSize, double insertionIndex, + double error) { + super(); + this.depTime = depTime; + this.tourSize = tourSize; + this.insertionIndex = insertionIndex; + this.error = error; + } + + } + + private String locationId = "70"; + + private double routeCostBefore; + private double estimatedMC; + private boolean beforeFirst = false; + + private RouteStates actStates; + + public void setActivityStates(RouteStates actStates){ + this.actStates = actStates; + } + + public ActivityState state(TourActivity act){ + return actStates.getState(act); + } + + + Collection infos = new ArrayList(); + + @Override + public void informJobInserted(int nOfJobsStill2Recreate, Job job2insert, VehicleRoute insertedIn) { + if(job2insert instanceof Service){ + if(((Service) job2insert).getLocationId().equals(locationId)){ + double actualMC = insertedIn.getCost()-routeCostBefore; + TourActivity act = getAct(job2insert,insertedIn); + double error = (estimatedMC-actualMC); + int tourSize = insertedIn.getTourActivities().getActivities().size(); + int insertionIndex = getIndexOf(job2insert, insertedIn); +// infos.add(new Info()) + double depTime = state(act).getEarliestOperationStart()+act.getOperationTime(); + infos.add(new Info(depTime,tourSize,insertionIndex,error)); +// System.out.println("[id=1][tourSize="+tourSize+"][index="+insertionIndex+ +// "][earliestDeparture="+depTime+ +// "][tourCostBefore="+routeCostBefore+"][routeCostAfter="+insertedIn.getCost()+"]" + +// "[estimated="+Math.round(estimatedMC)+"][actual="+Math.round(actualMC)+"][error(abs)="+error + +// "][errorPerNextCustomer="+ (error/(double)(tourSize-insertionIndex)) + "]"); + routeCostBefore = 0.0; + estimatedMC = 0.0; + if(!beforeFirst) throw new IllegalStateException("ähhh"); + beforeFirst = false; + } + } + } + + private TourActivity getAct(Job job2insert, VehicleRoute insertedIn) { + for(TourActivity act : insertedIn.getTourActivities().getActivities()){ + if(act instanceof JobActivity){ + if(((JobActivity) act).getJob().getId().equals(job2insert.getId())){ + return act; + } + } + } + return null; + } + + private int getIndexOf(Job job2insert, VehicleRoute insertedIn) { + int index=0; + for(TourActivity act : insertedIn.getTourActivities().getActivities()){ + if(act instanceof JobActivity){ + if(((JobActivity) act).getJob().getId().equals(job2insert.getId())){ + return index; + } + } + index++; + } + return -1; + } + + @Override + public void informBeforeJobInsertion(Job job, InsertionData data, VehicleRoute route) { + if(job instanceof Service){ + if(((Service) job).getLocationId().equals(locationId)){ +// System.out.println("[id=1][tourSize="+route.getTour().getActivities().size()+"][tourCost="+route.getCost()+"]" + +// "[estimatedMarginalInsertionCost="+data.getInsertionCost()+"]"); + routeCostBefore = route.getCost(); + estimatedMC = data.getInsertionCost(); + beforeFirst = true; + } + } + } + + @Override + public void informAlgorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + try { + BufferedWriter writer = new BufferedWriter(new FileWriter("output/errorAna.txt")); + for(Info info : infos){ + writer.write(new StringBuilder().append(info.depTime).append(";").append(info.tourSize).append(";").append(info.insertionIndex).append(";") + .append(info.error).append("\n").toString()); + } + writer.close(); + } catch (IOException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + } + +} diff --git a/jsprit-core/src/main/java/algorithms/JobRemover.java b/jsprit-core/src/main/java/algorithms/JobRemover.java new file mode 100644 index 00000000..c8d34d15 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobRemover.java @@ -0,0 +1,36 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.route.VehicleRoute; + +interface JobRemover { + + /** + * Removes jobs from vehicRoute and return true if job has been successfully removed. + * + * @return true if job removed successfully, otherwise false + */ + public boolean removeJobWithoutTourUpdate(Job job, VehicleRoute vehicleRoute); + + +} diff --git a/jsprit-core/src/main/java/algorithms/JobRemoverImpl.java b/jsprit-core/src/main/java/algorithms/JobRemoverImpl.java new file mode 100644 index 00000000..737fca0a --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/JobRemoverImpl.java @@ -0,0 +1,54 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.List; + +import basics.Job; +import basics.route.VehicleRoute; + +class JobRemoverImpl implements JobRemover{ + + interface RemoverListener { + public void informRemovedJob(Job j, VehicleRoute r); + } + + private List remListeners = new ArrayList(); + + @Override + public boolean removeJobWithoutTourUpdate(Job job, VehicleRoute vehicleRoute) { + boolean jobRemoved = vehicleRoute.getTourActivities().removeJob(job); + if(jobRemoved) informRemovedJob(job,vehicleRoute); + return jobRemoved; + } + + private void informRemovedJob(Job job, VehicleRoute vehicleRoute) { + for(RemoverListener l : remListeners) l.informRemovedJob(job, vehicleRoute); + } + + public List getRemListeners() { + return remListeners; + } + + + +} diff --git a/jsprit-core/src/main/java/algorithms/NeighborhoodThresholdInitialiser.java b/jsprit-core/src/main/java/algorithms/NeighborhoodThresholdInitialiser.java new file mode 100644 index 00000000..efd39118 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/NeighborhoodThresholdInitialiser.java @@ -0,0 +1,134 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; + +import org.apache.commons.math.stat.descriptive.moment.Mean; +import org.apache.commons.math.stat.descriptive.moment.StandardDeviation; +import org.apache.log4j.Logger; + +import util.CrowFlyCosts; +import util.EuclideanDistanceCalculator; +import util.Locations; +import util.NeighborhoodImpl; +import util.Solutions; +import algorithms.selectors.SelectBest; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmStartsListener; +import basics.algo.VehicleRoutingAlgorithmFactory; +import basics.route.TourActivity; +import basics.route.VehicleRoute; + +public class NeighborhoodThresholdInitialiser implements AlgorithmStartsListener{ + + private static Logger log = Logger.getLogger(NeighborhoodThresholdInitialiser.class); + + private NeighborhoodImpl neighborhood; + + private VehicleRoutingAlgorithmFactory routingAlgorithmFactory = new VehicleRoutingAlgorithmFactory() { + + @Override + public VehicleRoutingAlgorithm createAlgorithm(VehicleRoutingProblem vrp) { + VehicleRoutingAlgorithm algorithm = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "resources/config.xml"); + return algorithm; + } + }; + + private int crowFlySpeed = 20; + + public NeighborhoodThresholdInitialiser(NeighborhoodImpl neighborhood) { + this.neighborhood = neighborhood; + } + + + /** + * @param crowFlySpeed the crowFlySpeed to set + */ + public void setCrowFlySpeed(int crowFlySpeed) { + this.crowFlySpeed = crowFlySpeed; + } + + + /** + * @param routingAlgorithmFactory the routingAlgorithm to set + */ + public void setRoutingAlgorithmFactory(VehicleRoutingAlgorithmFactory routingAlgorithmFactory) { + this.routingAlgorithmFactory = routingAlgorithmFactory; + } + + public void initialise(VehicleRoutingProblem problem){ + informAlgorithmStarts(problem, null, null); + } + + @Override + public void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.addAllJobs(problem.getJobs().values()); + builder.addAllVehicles(problem.getVehicles()); + VehicleRoutingProblem pblm = builder.build(); + CrowFlyCosts crowFly = new CrowFlyCosts(builder.getLocations()); + crowFly.speed = crowFlySpeed; + pblm.setTransportCosts(crowFly); + + VehicleRoutingAlgorithm algo = routingAlgorithmFactory.createAlgorithm(pblm); + Collection mySolutions = algo.searchSolutions(); + + double threshold = determineThreshold(pblm,builder.getLocations(), mySolutions); + neighborhood.setThreshold(threshold); + neighborhood.initialise(); + } + + private double determineThreshold(VehicleRoutingProblem pblm, Locations locations, Collection mySolutions) { + VehicleRoutingProblemSolution bestSolution = Solutions.getBest(mySolutions); + double[] distances = new double[bestSolution.getRoutes().size()+pblm.getJobs().size()]; + getDistances(distances,bestSolution,locations); + Mean mean = new Mean(); + double meanValue = mean.evaluate(distances); + StandardDeviation dev = new StandardDeviation(); + double devValue = dev.evaluate(distances, meanValue); + log.info("mean="+meanValue+", dev="+devValue); + return meanValue + devValue; +// + 2*devValue; +// return Double.MAX_VALUE; + } + + private void getDistances(double[] distances, VehicleRoutingProblemSolution bestSolution, Locations locations) { + int index = 0; + for(VehicleRoute route : bestSolution.getRoutes()){ + TourActivity prev = null; + for(TourActivity act : route.getTourActivities().getActivities()){ + if(prev == null){ prev = act; continue; } + double dist = EuclideanDistanceCalculator.calculateDistance(locations.getCoord(prev.getLocationId()), locations.getCoord(act.getLocationId())); +// log.info("dist="+dist); + distances[index] = dist; + index++; + prev = act; + } +// double dist = EuclideanDistanceCalculator.calculateDistance(locations.getCoord(prev.getLocationId()), locations.getCoord(route.getEnd().getLocationId())); +// distances[index] = dist; +// index++; + } + } + +} diff --git a/jsprit-core/src/main/java/algorithms/ParRegretInsertion.java b/jsprit-core/src/main/java/algorithms/ParRegretInsertion.java new file mode 100644 index 00000000..d894e7f7 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/ParRegretInsertion.java @@ -0,0 +1,229 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +///******************************************************************************* +// * Copyright (c) 2011 Stefan Schroeder. +// * eMail: stefan.schroeder@kit.edu +// * +// * All rights reserved. This program and the accompanying materials +// * are made available under the terms of the GNU Public License v2.0 +// * which accompanies this distribution, and is available at +// * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html +// * +// * Contributors: +// * Stefan Schroeder - initial API and implementation +// ******************************************************************************/ +//package algorithms; +// +//import java.util.ArrayList; +//import java.util.Collection; +//import java.util.List; +//import java.util.concurrent.Callable; +//import java.util.concurrent.CompletionService; +//import java.util.concurrent.ExecutionException; +//import java.util.concurrent.ExecutorCompletionService; +//import java.util.concurrent.ExecutorService; +//import java.util.concurrent.Future; +// +//import org.apache.log4j.Logger; +// +//import basics.InsertionData; +//import basics.Job; +//import basics.Service; +//import basics.Shipment; +//import basics.VehicleRoute; +//import basics.InsertionData.NoInsertionFound; +// +// +// +// +// +// +// +///** +// * Simplest recreation strategy. All removed customers are inserted where insertion costs are minimal. I.e. each tour-agent is asked for +// * minimal marginal insertion costs. The tour-agent offering the lowest marginal insertion costs gets the customer/shipment. +// * +// * @author stefan schroeder +// * +// */ +// +//final class ParRegretInsertion extends AbstractRecreationStrategy{ +// +// +// private Logger logger = Logger.getLogger(ParRegretInsertion.class); +// +// +// public static double scoreParam_of_timeWindowLegth = 0.0; +// +// private ExecutorService executor; +// +// public static double scoreParam_of_distance = 0.5; +// +// private DepotDistance depotDistance; +// +// private RouteAlgorithm routeAlgorithm; +// +// private VehicleRouteFactory vehicleRouteFactory; +// +// public ParRegretInsertion(ExecutorService executor, RouteAlgorithm routeAlgorithm, VehicleRouteFactory routeFactory, DepotDistance depotDistance) { +// super(); +// this.executor = executor; +// this.routeAlgorithm = routeAlgorithm; +// this.depotDistance = depotDistance; +// this.vehicleRouteFactory = routeFactory; +// } +// +// +// @Override +// public void recreate(final Collection vehicleRoutes, Collection unassignedJobs, double result2beat) { +// List jobs = new ArrayList(unassignedJobs); +// informRecreationStart(unassignedJobs.size()); +// +// while(!jobs.isEmpty()){ +// List unassignedJobList = new ArrayList(jobs); +// ScoredJob bestScoredJob = null; +// double bestScore = -1*Double.MAX_VALUE; +// CompletionService completionService = new ExecutorCompletionService(executor); +// +// for(final Job unassignedJob : unassignedJobList){ +// completionService.submit(new Callable(){ +// +// @Override +// public ScoredJob call() throws Exception { +// return getScoredJob(vehicleRoutes, unassignedJob); +// } +// +// }); +// +// } +// try{ +// for(int i=0;i fsj = completionService.take(); +// ScoredJob scoredJob = fsj.get(); +// if(scoredJob == null){ +// continue; +// } +// if(scoredJob.getScore() > bestScore){ +// bestScoredJob = scoredJob; +// bestScore = scoredJob.getScore(); +// } +// } +// } +// catch(InterruptedException e){ +// Thread.currentThread().interrupt(); +// } +// catch (ExecutionException e) { +// e.printStackTrace(); +// logger.error(e.getCause().toString()); +// System.exit(1); +// } +// if(bestScoredJob == null){ +// Job job = unassignedJobList.get(0); +// VehicleRoute newRoute = vehicleRouteFactory.createVehicleRoute(); +// InsertionData bestI = routeAlgorithm.calculateBestInsertion(newRoute, job, Double.MAX_VALUE); +// if(bestI instanceof InsertionData.NoInsertionFound) throw new IllegalStateException("given the vehicles, could not create a valid solution"); +// routeAlgorithm.insertJob(job,bestI,newRoute); +// vehicleRoutes.add(newRoute); +// jobs.remove(job); +// +// } +// else{ +// routeAlgorithm.insertJob(bestScoredJob.getJob(),bestScoredJob.getInsertionData(),bestScoredJob.getRoute()); +// jobs.remove(bestScoredJob.getJob()); +// } +// informJobInsertion(null, (unassignedJobList.size()-1), null); +// } +// } +// +// private ScoredJob getScoredJob(Collection vehicleRoutes, Job job){ +// InsertionData best = null; +// InsertionData secondBest = null; +// VehicleRoute bestRoute = null; +// double benchmark = Double.MAX_VALUE; +// for(VehicleRoute route : vehicleRoutes){ +// if(secondBest != null){ +// benchmark = secondBest.getInsertionCost(); +// } +// InsertionData iData = routeAlgorithm.calculateBestInsertion(route, job, benchmark); +// if(iData instanceof NoInsertionFound) continue; +// if(best == null) { +// best = iData; +// bestRoute = route; +// } +// else if(iData.getInsertionCost() < best.getInsertionCost()){ +// secondBest = best; +// best = iData; +// bestRoute = route; +// } +// else if(secondBest == null) secondBest = iData; +// else if(iData.getInsertionCost() < secondBest.getInsertionCost()) secondBest = iData; +// } +// if(best == null){ +// return null; +// } +// double score = score(job,best,secondBest); +// return new ScoredJob(job, score, best, bestRoute); +// } +// +// private double score(Job unassignedJob, InsertionData best, InsertionData secondBest) { +// /* +// * wieder so eine bescheuerte fallunterscheidung. hier will ich +// * doch einfach nur das maßgebende zeitfenster des jobs +// * job.getTimeWindow() +// * Problem: eine Shipment hat zwei TWs, sowohl ein PickupTW als auch +// * ein DeliveryTW +// */ +// double twStart = 0.0; +// double twEnd = 0.0; +// if(unassignedJob instanceof Shipment){ +// twStart = ((Shipment) unassignedJob).getDeliveryTW().getStart(); +// twEnd = ((Shipment) unassignedJob).getDeliveryTW().getEnd(); +// } +// else if(unassignedJob instanceof Service){ +// twStart = ((Service) unassignedJob).getTimeWindow().getStart(); +// twEnd = ((Service) unassignedJob).getTimeWindow().getEnd(); +// } +// if(best == null){ +// throw new IllegalStateException("cannot insert job " + unassignedJob.getId()); +// } +// if(secondBest == null){ +// return Double.MAX_VALUE; +// } +//// double score = (secondBest.getInsertionCost()-best.getInsertionCost()) + scoreParam_of_distance*getDistance(unassignedJob) - scoreParam_of_timeWindowLegth*(twEnd-twStart); +//// logger.info("priceDiff="+ (secondBest.getPrice()-best.getPrice()) + "; param*dist=" +// double timeWindowInfluence = scoreParam_of_timeWindowLegth*(twEnd-twStart); +// double distanceInfluence = scoreParam_of_distance*getDistance(unassignedJob); +// double score = (secondBest.getInsertionCost()-best.getInsertionCost()) - timeWindowInfluence +// + distanceInfluence; +// return score; +// } +// +// private double getDistance(Job unassignedJob) { +// return depotDistance.calcDistance(unassignedJob); +// } +// +// +// public double getTimeParam() { +// return scoreParam_of_timeWindowLegth; +// } +// +// +//} diff --git a/jsprit-core/src/main/java/algorithms/RegretInsertion.java b/jsprit-core/src/main/java/algorithms/RegretInsertion.java new file mode 100644 index 00000000..46ad780b --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RegretInsertion.java @@ -0,0 +1,210 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import org.apache.log4j.Logger; + +import algorithms.InsertionData.NoInsertionFound; +import basics.Job; +import basics.Service; +import basics.route.VehicleRoute; + + +/** + * Insertion based an regret approach. + * + *

Basically calculates the insertion cost of the firstBest and the secondBest alternative. The score is then calculated as difference + * between secondBest and firstBest, plus additional scoring variables that can defined in this.ScoringFunction. + * The idea is that if the cost of the secondBest alternative is way higher than the first best, it seems to be important to insert this + * customer immediatedly. If difference is not that high, it might not impact solution if this customer is inserted later. + * + * @author stefan schroeder + * + */ +final class RegretInsertion extends AbstractInsertionStrategy{ + + /** + * Scorer to include other impacts on score such as time-window length or distance to depot. + * + * @author schroeder + * + */ + static interface ScoringFunction { + + public double score(Job job); + + } + + /** + * Scorer that includes the length of the time-window when scoring a job. The wider the time-window, the lower the score. + * + *

This is the default scorer, i.e.: score = (secondBest - firstBest) + this.TimeWindowScorer.score(job) + * + * @author schroeder + * + */ + static class TimeWindowScorer implements ScoringFunction { + + private double tw_scoringParam = - 0.1; + + @Override + public double score(Job job) { + double twStart = 0.0; + double twEnd = 0.0; +// if(job instanceof Shipment){ +// twStart = ((Shipment) job).getDeliveryTW().getStart(); +// twEnd = ((Shipment) job).getDeliveryTW().getEnd(); +// } +// else + if(job instanceof Service){ + twStart = ((Service) job).getTimeWindow().getStart(); + twEnd = ((Service) job).getTimeWindow().getEnd(); + } + return (twEnd-twStart)*tw_scoringParam; + } + + @Override + public String toString() { + return "[name=timeWindowScorer][scoringParam="+tw_scoringParam+"]"; + } + + } + + public static RegretInsertion newInstance(RouteAlgorithm routeAlgorithm) { + return new RegretInsertion(routeAlgorithm); + } + + private Logger logger = Logger.getLogger(RegretInsertion.class); + + private RouteAlgorithm routeAlgorithm; + + private ScoringFunction scoringFunction = new TimeWindowScorer(); + + /** + * Sets the scoring function. + * + *

By default, the this.TimeWindowScorer is used. + * + * @param scoringFunction + */ + public void setScoringFunction(ScoringFunction scoringFunction) { + this.scoringFunction = scoringFunction; + } + + public RegretInsertion(RouteAlgorithm routeAlgorithm) { + super(); + this.routeAlgorithm = routeAlgorithm; + logger.info("initialise " + this); + } + + @Override + public String toString() { + return "[name=regretInsertion][additionalScorer="+scoringFunction+"]"; + } + + public RouteAlgorithm getRouteAlgorithm(){ + return routeAlgorithm; + } + + /** + * Runs insertion. + * + *

Before inserting a job, all unassigned jobs are scored according to its best- and secondBest-insertion plus additional scoring variables. + * + */ + @Override + public void run(Collection routes, Collection unassignedJobs, double resultToBeat) { + List jobs = new ArrayList(unassignedJobs); + informInsertionStarts(routes,unassignedJobs.size()); + int inserted = 0; + while(!jobs.isEmpty()){ + List unassignedJobList = new ArrayList(jobs); + ScoredJob bestScoredJob = null; + double bestScore = -1*Double.MAX_VALUE; + VehicleRoute insertIn = null; + + for(Job unassignedJob : unassignedJobList){ + InsertionData best = null; + InsertionData secondBest = null; + VehicleRoute bestRoute = null; + + double benchmark = Double.MAX_VALUE; + for(VehicleRoute route : routes){ + if(secondBest != null){ + benchmark = secondBest.getInsertionCost(); + } + InsertionData iData = routeAlgorithm.calculateBestInsertion(route, unassignedJob, benchmark); + if(iData instanceof NoInsertionFound) continue; + if(best == null){ + best = iData; + bestRoute = route; + } + else if(iData.getInsertionCost() < best.getInsertionCost()){ + secondBest = best; + best = iData; + bestRoute = route; + } + else if(secondBest == null || (iData.getInsertionCost() < secondBest.getInsertionCost())){ + secondBest = iData; + } + } + if(best == null){ + break; + } + double score = score(unassignedJob,best,secondBest); + if(score > bestScore){ + bestScoredJob = new ScoredJob(unassignedJob,score,best,bestRoute); + bestScore = score; + } + } + Job assignedJob; + if(bestScoredJob == null){ + Job job = unassignedJobList.get(0); + VehicleRoute newRoute = VehicleRoute.emptyRoute(); + InsertionData bestI = routeAlgorithm.calculateBestInsertion(newRoute, job, Double.MAX_VALUE); + if(bestI instanceof InsertionData.NoInsertionFound) throw new IllegalStateException("given the vehicles, could not create a valid solution"); + insertIn=newRoute; + assignedJob=job; + routeAlgorithm.insertJob(job,bestI,newRoute); + routes.add(newRoute); + jobs.remove(job); + + } + else{ + routeAlgorithm.insertJob(bestScoredJob.getJob(),bestScoredJob.getInsertionData(), bestScoredJob.getRoute()); + insertIn=bestScoredJob.getRoute(); + assignedJob=bestScoredJob.getJob(); + jobs.remove(bestScoredJob.getJob()); + } + inserted++; + informJobInserted((unassignedJobList.size()-inserted), assignedJob, insertIn); + + } + } + + private double score(Job unassignedJob, InsertionData best, InsertionData secondBest) { + if(best == null){ + throw new IllegalStateException("cannot insert job " + unassignedJob.getId()); + } + if(secondBest == null){ + return Double.MAX_VALUE; + } + return (secondBest.getInsertionCost()-best.getInsertionCost()) + scoringFunction.score(unassignedJob); + + } + +} diff --git a/jsprit-core/src/main/java/algorithms/RemoveEmptyVehicles.java b/jsprit-core/src/main/java/algorithms/RemoveEmptyVehicles.java new file mode 100644 index 00000000..16796f87 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RemoveEmptyVehicles.java @@ -0,0 +1,57 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; +import org.apache.log4j.Logger; + + +import basics.algo.InsertionEndsListener; +import basics.algo.InsertionStartsListener; +import basics.route.VehicleRoute; + +class RemoveEmptyVehicles implements InsertionStartsListener, InsertionEndsListener{ + + private static Logger log = Logger.getLogger(RemoveEmptyVehicles.class); + + @Override + public void informInsertionStarts(Collection vehicleRoutes, int nOfJobs2Recreate) { +// List routes = new ArrayList(vehicleRoutes); +// for(VehicleRoute route : routes){ +// if(route.isEmpty()) { vehicleRoutes.remove(route); } +// } + } + + @Override + public String toString() { + return "[name=removeEmptyVehicles]"; + } + + @Override + public void informInsertionEnds(Collection vehicleRoutes) { + List routes = new ArrayList(vehicleRoutes); + for(VehicleRoute route : routes){ + if(route.isEmpty()) { vehicleRoutes.remove(route); } + } + } +} diff --git a/jsprit-core/src/main/java/algorithms/ResetAndIniFleetManager.java b/jsprit-core/src/main/java/algorithms/ResetAndIniFleetManager.java new file mode 100644 index 00000000..98e2a669 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/ResetAndIniFleetManager.java @@ -0,0 +1,56 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; + +import org.apache.log4j.Logger; + +import basics.algo.InsertionStartsListener; +import basics.route.VehicleRoute; + +class ResetAndIniFleetManager implements InsertionStartsListener{ + + private static Logger log = Logger.getLogger(ResetAndIniFleetManager.class); + + private VehicleFleetManager vehicleFleetManager; + + ResetAndIniFleetManager(VehicleFleetManager vehicleFleetManager) { + super(); + this.vehicleFleetManager = vehicleFleetManager; + } + + @Override + public void informInsertionStarts(Collection vehicleRoutes, int nOfJobs2Recreate) { + vehicleFleetManager.unlockAll(); + for(VehicleRoute route : vehicleRoutes){ + if(!route.isEmpty()){ + vehicleFleetManager.lock(route.getVehicle()); + } + } +// log.info("#lockedVehicles=" + ((VehicleFleetManagerImpl)vehicleFleetManager).sizeOfLockedVehicles() + " #routes="+vehicleRoutes.size()); + } + + @Override + public String toString() { + return "[name=resetAndIniFleetManager]"; + } +} diff --git a/jsprit-core/src/main/java/algorithms/RouteAlgorithm.java b/jsprit-core/src/main/java/algorithms/RouteAlgorithm.java new file mode 100644 index 00000000..351a9fa6 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RouteAlgorithm.java @@ -0,0 +1,92 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; + +import basics.Job; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + +interface RouteAlgorithm { + + interface RouteAlgorithmListener { + + } + + interface JobRemovedListener extends RouteAlgorithmListener{ + public void removed(VehicleRoute route, Job job); + } + + interface JobInsertedListener extends RouteAlgorithmListener{ + public void inserted(VehicleRoute route, Job job); + } + + interface VehicleSwitchedListener extends RouteAlgorithmListener{ + public void vehicleSwitched(Vehicle oldVehicle, Vehicle newVehicle); + } + + /** + * Calculates the best insertion position and the corresponding marginal costs of inserting the job (according to the insertionCostCalculator). + * This does not affect any input parameter, thus the vehicleRoute and its data will not be changed/affected. + * + * @param VehicleRoute, Job, double + * @return InsertionData + */ + public InsertionData calculateBestInsertion(VehicleRoute vehicleRoute, Job job, double bestKnownPrice); + + /** + * Removes job from vehicleRoute and does not update the resulting tour. Thus the tour state might not be valid anymore. + * Note that this changes vehicleRoute! + * + * @return true if job removed successfully, otherwise false + */ + public boolean removeJobWithoutTourUpdate(Job job, VehicleRoute vehicleRoute); + + /** + * Removes job from input parameter vehicleRoute AND updates the state of the resulting tour with tourStateCalc. + * Note that this changes para vehicleRoute! + */ + public boolean removeJob(Job job, VehicleRoute vehicleRoute); + + /** + * Inserts job into vehicleRoute.getTour(). + * Please note, that this changes the parameter vehicleRoute! + */ + public void insertJobWithoutTourUpdate(VehicleRoute vehicleRoute, Job job, InsertionData insertionData); + + /** + * Inserts job into vehicleRoute.getTour(). + * Please note, that this changes the parameter vehicleRoute! + */ + public void insertJob(Job job, InsertionData insertionData, VehicleRoute vehicleRoute); + + /** + * Updates vehicleRoute, i.e. uses the tourStateCalculator to update for example timeWindows and loads on vehicleRoute.getTour() + * Note that this changes the parameter vehicleRoute! + */ + public void updateTour(VehicleRoute vehicleRoute); + + public Collection getListeners(); + + +} diff --git a/jsprit-core/src/main/java/algorithms/RouteAlgorithmImpl.java b/jsprit-core/src/main/java/algorithms/RouteAlgorithmImpl.java new file mode 100644 index 00000000..2d9062d8 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RouteAlgorithmImpl.java @@ -0,0 +1,181 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; + +import org.apache.log4j.Logger; + +import algorithms.RouteStates.ActivityState; +import algorithms.InsertionData.NoInsertionFound; +import basics.Job; +import basics.Service; +import basics.route.ServiceActivity; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + +/** + * + * @author stefan schroeder + * + */ + +final class RouteAlgorithmImpl implements RouteAlgorithm { + + private static Logger logger = Logger.getLogger(RouteAlgorithmImpl.class); + + static double NO_DEPARTURE_TIME = -12345.12345; + + private String algoDescription = "algorithm to remove and insert jobs from vehicleRoutes. it also calculates marginal costs of the best insertion of a " + + "job into the given vehicle route"; + + public static RouteAlgorithmImpl newInstance(JobInsertionCalculator jobInsertionCalculator, VehicleRouteUpdater tourStateCalculator){ + return new RouteAlgorithmImpl(jobInsertionCalculator, tourStateCalculator); + } + + private Collection listeners = new ArrayList(); + + private VehicleRouteUpdater tourCalculator; + + private JobInsertionCalculator insertionCostCalculator; + + private RouteStates actStates; + + public void setActivityStates(RouteStates actStates){ + this.actStates = actStates; + } + + public ActivityState state(TourActivity act){ + return actStates.getState(act); + } + + private RouteAlgorithmImpl(JobInsertionCalculator insertionCostCalculator, VehicleRouteUpdater tourCalculator){ + this.tourCalculator = tourCalculator; + this.insertionCostCalculator = insertionCostCalculator; + } + + + public InsertionData calculateBestInsertion(VehicleRoute vehicleRoute, Job job, double bestKnownCost) { + return insertionCostCalculator.calculate(vehicleRoute, job, null, NO_DEPARTURE_TIME, null, bestKnownCost); + } + + + public boolean removeJobWithoutTourUpdate(Job job, VehicleRoute vehicleRoute) { + boolean removed = vehicleRoute.getTourActivities().removeJob(job); + if(removed){ + jobRemoved(vehicleRoute,job); + } + return removed; + } + + private void jobRemoved(VehicleRoute vehicleRoute, Job job) { + for(RouteAlgorithmListener l : listeners){ + if(l instanceof JobRemovedListener){ + ((JobRemovedListener) l).removed(vehicleRoute, job); + } + } + } + + + public boolean removeJob(Job job, VehicleRoute vehicleRoute){ + boolean removed = removeJobWithoutTourUpdate(job, vehicleRoute); + if(removed) updateTour(vehicleRoute); + return removed; + } + + + public void updateTour(VehicleRoute vehicleRoute){ + boolean tourIsFeasible = tourCalculator.updateRoute(vehicleRoute); + if(!tourIsFeasible){ + throw new IllegalStateException("At this point tour should be feasible. but it is not. \n currentTour=" + vehicleRoute.getTourActivities() + + "\n error sources: check jobInsertionCostCalculators and actInsertionCalculators. somehow an insertion is made, althought a hard constraint is broken. Here, hard constraints refer to \n" + + "hard time-window constraints. If you want to deal with such constraints, make sure a violation is penalized properly (such that it can never be the best insertion position). \n" + + "If you use CalculatesServiceInsertion and CalculatesActivityInsertion, the only hard constraint is the vehicle-capacity constraints. A violation of time-windows must be penalized in \n" + + "the vehicleRouteCostFunction. For example: in handleActivity(....) one can check whether the act start-time is higher than the latestOperationStartTime. If so penalize it with a very high value. \n" + + "For example: \n" + + "public void handleActivity(TourActivity tourAct, double startTime, double endTime) {\n" + + "\tif(startTime > tourAct.getLatestOperationStartTime()){\n" + + "\t\tcost += Double.MAX_VALUE;\n" + + "\t}\n" + + "});"); + } + } + + + @Override + public void insertJobWithoutTourUpdate(VehicleRoute vehicleRoute, Job job, InsertionData insertionData) { + if(insertionData == null || (insertionData instanceof NoInsertionFound)) throw new IllegalStateException("insertionData null. cannot insert job."); + if(job == null) throw new IllegalStateException("cannot insert null-job"); + if(!(vehicleRoute.getVehicle().getId().toString().equals(insertionData.getSelectedVehicle().getId().toString()))){ + vehicleSwitched(vehicleRoute.getVehicle(),insertionData.getSelectedVehicle()); + vehicleRoute.setVehicle(insertionData.getSelectedVehicle(), insertionData.getVehicleDepartureTime()); + } + if(job instanceof Service) { + vehicleRoute.getTourActivities().addActivity(insertionData.getDeliveryInsertionIndex(), ServiceActivity.newInstance((Service)job)); +// if(vehicleRoute.getStart().getEndTime() != insertionData.getVehicleDepartureTime()){ +// logger.info("depTime switched from " + vehicleRoute.getStart().getEndTime() + " to " + insertionData.getVehicleDepartureTime()); +// } + vehicleRoute.setDepartureTime(insertionData.getVehicleDepartureTime()); + } + else throw new IllegalStateException("neither service nor shipment. this is not supported."); + jobInserted(vehicleRoute,job); + } + + + + private void vehicleSwitched(Vehicle oldVehicle, Vehicle newVehicle) { + for(RouteAlgorithmListener l : listeners){ + if(l instanceof VehicleSwitchedListener){ + ((VehicleSwitchedListener) l).vehicleSwitched(oldVehicle,newVehicle); + } + } + } + + private void jobInserted(VehicleRoute vehicleRoute, Job job) { + for(RouteAlgorithmListener l : listeners){ + if(l instanceof JobInsertedListener){ + ((JobInsertedListener) l).inserted(vehicleRoute, job); + } + } + } + + + public void insertJob(Job job, InsertionData insertionData, VehicleRoute vehicleRoute){ + insertJobWithoutTourUpdate(vehicleRoute, job, insertionData); + updateTour(vehicleRoute); + } + + @Override + public String toString() { + return algoDescription; + } + + private void insertJob(Service service, int serviceInsertionIndex, VehicleRoute vehicleRoute) { +// TourActivity del = actStates.getActivity(service,true); + vehicleRoute.getTourActivities().addActivity(serviceInsertionIndex, ServiceActivity.newInstance(service)); + } + + + + public Collection getListeners() { + return listeners; + } + + public void setAlgoDescription(String algoDescription) { + this.algoDescription = algoDescription; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/RouteStates.java b/jsprit-core/src/main/java/algorithms/RouteStates.java new file mode 100644 index 00000000..19c770c7 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RouteStates.java @@ -0,0 +1,208 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmEndsListener; +import basics.algo.IterationEndsListener; +import basics.algo.IterationStartsListener; +import basics.route.ServiceActivity; +import basics.route.TourActivity; +import basics.route.VehicleRoute; + +class RouteStates implements IterationStartsListener{ + + Logger log = Logger.getLogger(RouteStates.class); + + static class RouteState { + private double costs; + private int load; + private VehicleRoute route; + public RouteState(VehicleRoute route) { + super(); + this.route = route; + } + /** + * @return the costs + */ + public double getCosts() { + return costs; + } + /** + * @param costs the costs to set + */ + public void setCosts(double costs) { + this.costs = costs; + } + /** + * @return the load + */ + public int getLoad() { + return load; + } + /** + * @param load the load to set + */ + public void setLoad(int load) { + this.load = load; + } + + } + + static class ActivityState { + private double earliestOperationStart; + private double latestOperationStart; + private double currentLoad; + private double currentCost; + private TourActivity act; + + public ActivityState(TourActivity activity){ + this.earliestOperationStart=activity.getTheoreticalEarliestOperationStartTime(); + this.latestOperationStart=activity.getTheoreticalLatestOperationStartTime(); + this.act = activity; + } + + @Override + public String toString() { + return "[earliestStart="+earliestOperationStart+"][latestStart="+ + latestOperationStart+"][currLoad="+currentLoad+"][currCost="+currentCost+"]"; + } + + public double getEarliestOperationStart() { + return earliestOperationStart; + } + + void setEarliestOperationStart(double earliestOperationStart) { + this.earliestOperationStart = earliestOperationStart; + } + + public double getLatestOperationStart() { + return latestOperationStart; + } + + void setLatestOperationStart(double latestOperationStart) { + this.latestOperationStart = latestOperationStart; + } + + public double getCurrentLoad() { + return currentLoad; + } + + void setCurrentLoad(double currentLoad) { + this.currentLoad = currentLoad; + } + + public double getCurrentCost() { + return currentCost; + } + + void setCurrentCost(double currentCost) { + this.currentCost = currentCost; + } + + public void reset() { + earliestOperationStart = act.getTheoreticalEarliestOperationStartTime(); + latestOperationStart = act.getTheoreticalLatestOperationStartTime() ; + currentLoad = 0.0; + currentCost = 0.0; + } + } + + + private Map activityStates; + + private Map tourActivities; + + private Map routeStates; + + public RouteStates() { + activityStates = new HashMap(); + tourActivities = new HashMap(); + routeStates = new HashMap(); + } + + ActivityState getState(TourActivity act){ + if(!activityStates.containsKey(act)) return null; + return activityStates.get(act); + } + + public void clearStates(){ + activityStates.clear(); + } + + public Map getActivityStates() { + return activityStates; + } + + TourActivity getActivity(Service service, boolean resetState){ + TourActivity tourActivity = tourActivities.get(service); + getState(tourActivity).reset(); + return tourActivity; + } + + public void resetRouteStates(){ + routeStates.clear(); + } + + public RouteState getRouteState(VehicleRoute route){ + RouteState routeState = routeStates.get(route); + if(routeState == null){ + routeState = new RouteState(route); + putRouteState(route, routeState); + } + return routeState; + } + + private void putRouteState(VehicleRoute route, RouteState routeState){ + routeStates.put(route, routeState); + } + + void initialiseStateOfJobs(Collection jobs){ + for(Job job : jobs){ + if(job instanceof Service){ + ServiceActivity service = ServiceActivity.newInstance((Service)job); + ActivityState state = new ActivityState(service); + tourActivities.put((Service) job, service); + activityStates.put(service, state); + } + else{ + throw new IllegalStateException(); + } + } + } + + @Override + public void informIterationStarts(int i, VehicleRoutingProblem problem, Collection solutions) { + resetRouteStates(); + } + + + +} diff --git a/jsprit-core/src/main/java/algorithms/RuinRadial.java b/jsprit-core/src/main/java/algorithms/RuinRadial.java new file mode 100644 index 00000000..82cb3ed6 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RuinRadial.java @@ -0,0 +1,207 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Random; +import java.util.TreeSet; + +import org.apache.log4j.Logger; + +import util.RandomNumberGeneration; +import util.StopWatch; +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.SearchStrategyModule; +import basics.route.VehicleRoute; + + + +final class RuinRadial implements RuinStrategy { + + private final static String NAME = "radialRuin"; + + /** + * returns a new creation of instance of ruinRadial + * @param vrp + * @param fraction TODO + * @param jobDistance + * @param jobRemover TODO + * @param routeUpdater TODO + * @return + */ + static RuinRadial newInstance(VehicleRoutingProblem vrp, double fraction, JobDistance jobDistance, JobRemover jobRemover, VehicleRouteUpdater routeUpdater){ + return new RuinRadial(vrp, fraction, jobDistance, jobRemover, routeUpdater); + } + + + static class ReferencedJob { + private Job job; + private double distance; + + public ReferencedJob(Job job, double distance) { + super(); + this.job = job; + this.distance = distance; + } + + public Job getJob() { + return job; + } + + public double getDistance() { + return distance; + } + } + + private Logger logger = Logger.getLogger(RuinRadial.class); + + private VehicleRoutingProblem vrp; + + private double fractionOfAllNodes2beRuined; + + private Map> distanceNodeTree = new HashMap>(); + + private Random random = RandomNumberGeneration.getRandom(); + + private JobDistance jobDistance; + + private JobRemover jobRemover; + + private VehicleRouteUpdater routeUpdater; + + public void setRandom(Random random) { + this.random = random; + } + + public RuinRadial(VehicleRoutingProblem vrp, double fraction, JobDistance jobDistance, JobRemover jobRemover, VehicleRouteUpdater routeUpdater) { + super(); + this.vrp = vrp; + this.jobDistance = jobDistance; + this.jobRemover = jobRemover; + this.routeUpdater = routeUpdater; + this.fractionOfAllNodes2beRuined = fraction; + calculateDistancesFromJob2Job(); + logger.info("intialise " + this); + } + + public void setRuinFraction(double fractionOfAllNodes) { + this.fractionOfAllNodes2beRuined = fractionOfAllNodes; + logger.info("fraction set " + this); + } + + private void calculateDistancesFromJob2Job() { + logger.info("preprocess distances between locations ..."); + StopWatch stopWatch = new StopWatch(); + stopWatch.start(); + int nuOfDistancesStored = 0; + for (Job i : vrp.getJobs().values()) { + TreeSet treeSet = new TreeSet( + new Comparator() { + @Override + public int compare(ReferencedJob o1, ReferencedJob o2) { + if (o1.getDistance() <= o2.getDistance()) { + return 1; + } else { + return -1; + } + } + }); + distanceNodeTree.put(i.getId(), treeSet); + for (Job j : vrp.getJobs().values()) { + double distance = jobDistance.calculateDistance(i, j); + ReferencedJob refNode = new ReferencedJob(j, distance); + treeSet.add(refNode); + nuOfDistancesStored++; + } + } + stopWatch.stop(); + logger.info("preprocessing comp-time: " + stopWatch + "; nuOfDistances stored: " + nuOfDistancesStored + "; estimated memory: " + + (distanceNodeTree.keySet().size()*64+nuOfDistancesStored*92) + " bytes"); + } + + @Override + public String toString() { + return "[name=radialRuin][fraction="+fractionOfAllNodes2beRuined+"]"; + } + + @Override + public Collection ruin(Collection vehicleRoutes) { + if(vehicleRoutes.isEmpty()){ + return Collections.EMPTY_LIST; + } + int nOfJobs2BeRemoved = getNuOfJobs2BeRemoved(); + if (nOfJobs2BeRemoved == 0) { + return Collections.EMPTY_LIST; + } + Job randomJob = pickRandomJob(); + Collection unassignedJobs = ruin(vehicleRoutes,randomJob,nOfJobs2BeRemoved); + return unassignedJobs; + } + + public Collection ruin(Collection vehicleRoutes, Job targetJob, int nOfJobs2BeRemoved){ + List unassignedJobs = new ArrayList(); + TreeSet tree = distanceNodeTree.get(targetJob.getId()); + Iterator descendingIterator = tree.descendingIterator(); + int counter = 0; + while (descendingIterator.hasNext() && counter < nOfJobs2BeRemoved) { + ReferencedJob refJob = descendingIterator.next(); + Job job = refJob.getJob(); + unassignedJobs.add(job); + counter++; + boolean removed = false; + for (VehicleRoute route : vehicleRoutes) { + removed = jobRemover.removeJobWithoutTourUpdate(job, route); + if (removed) { + break; + } + } + } + for(VehicleRoute route : vehicleRoutes){ + routeUpdater.updateRoute(route); + } + return unassignedJobs; + } + + private Job pickRandomJob() { + int totNuOfJobs = vrp.getJobs().values().size(); + int randomIndex = random.nextInt(totNuOfJobs); + Job job = new ArrayList(vrp.getJobs().values()).get(randomIndex); + return job; + } + + private int getNuOfJobs2BeRemoved() { + return (int) Math.ceil(vrp.getJobs().values().size() + * fractionOfAllNodes2beRuined); + } + +// @Override +// public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { +// ruin(vrpSolution.getRoutes()); +// return vrpSolution; +// } +// +// @Override +// public String getName() { +// return NAME; +// } + +} diff --git a/jsprit-core/src/main/java/algorithms/RuinRandom.java b/jsprit-core/src/main/java/algorithms/RuinRandom.java new file mode 100644 index 00000000..9180f13a --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RuinRandom.java @@ -0,0 +1,151 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.LinkedList; +import java.util.List; +import java.util.Random; + +import org.apache.log4j.Logger; + +import util.RandomNumberGeneration; +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.route.VehicleRoute; + + +/** + * Ruin strategy that ruins current solution randomly. I.e. + * customer are removed randomly from current solution. + * + * @author stefan schroeder + * + */ + +final class RuinRandom implements RuinStrategy { + + public static RuinRandom newInstance(VehicleRoutingProblem vrp, double fraction, JobRemover jobRemover, VehicleRouteUpdater routeUpdater){ + return new RuinRandom(vrp, fraction, jobRemover, routeUpdater); + } + + private Logger logger = Logger.getLogger(RuinRandom.class); + + private VehicleRoutingProblem vrp; + + private double fractionOfAllNodes2beRuined; + + private Random random = RandomNumberGeneration.getRandom(); + + private JobRemover jobRemover; + + private VehicleRouteUpdater vehicleRouteUpdater; + + public void setRandom(Random random) { + this.random = random; + } + + /** + * Constructs ruinRandom. + * + * @param vrp + * @param fraction which is the fraction of total c + * @param jobRemover + * @param vehicleRouteUpdater + */ + public RuinRandom(VehicleRoutingProblem vrp, double fraction, JobRemover jobRemover, VehicleRouteUpdater vehicleRouteUpdater) { + super(); + this.vrp = vrp; + this.jobRemover = jobRemover; + this.vehicleRouteUpdater = vehicleRouteUpdater; + this.fractionOfAllNodes2beRuined = fraction; + logger.info("initialise " + this); + logger.info("done"); + } + + /** + * Removes a fraction of jobs from vehicleRoutes. + * + *

The number of jobs is calculated as follows: Math.ceil(vrp.getJobs().values().size() * fractionOfAllNodes2beRuined). + */ + @Override + public Collection ruin(Collection vehicleRoutes) { + List unassignedJobs = new ArrayList(); + int nOfJobs2BeRemoved = selectNuOfJobs2BeRemoved(); + ruin(vehicleRoutes, nOfJobs2BeRemoved, unassignedJobs); + return unassignedJobs; + } + + /** + * Removes nOfJobs2BeRemoved from vehicleRoutes, including targetJob. + */ + @Override + public Collection ruin(Collection vehicleRoutes, Job targetJob, int nOfJobs2BeRemoved) { + List unassignedJobs = new ArrayList(); + if(targetJob != null){ + boolean removed = false; + for (VehicleRoute route : vehicleRoutes) { + removed = jobRemover.removeJobWithoutTourUpdate(targetJob, route); + if (removed) { + nOfJobs2BeRemoved--; + unassignedJobs.add(targetJob); + break; + } + } + } + ruin(vehicleRoutes, nOfJobs2BeRemoved, unassignedJobs); + return unassignedJobs; + } + + public void setRuinFraction(double fractionOfAllNodes2beRuined) { + this.fractionOfAllNodes2beRuined = fractionOfAllNodes2beRuined; + logger.info("fraction set " + this); + } + + private void ruin(Collection vehicleRoutes,int nOfJobs2BeRemoved, List unassignedJobs) { + LinkedList availableJobs = new LinkedList(vrp.getJobs().values()); + for (int i = 0; i < nOfJobs2BeRemoved; i++) { + Job job = pickRandomJob(availableJobs); + unassignedJobs.add(job); + availableJobs.remove(job); + for (VehicleRoute route : vehicleRoutes) { + boolean removed = jobRemover.removeJobWithoutTourUpdate(job, route); + if (removed) break; + } + } + updateRoutes(vehicleRoutes); + } + + private void updateRoutes(Collection vehicleRoutes) { + for(VehicleRoute route : vehicleRoutes){ + vehicleRouteUpdater.updateRoute(route); + } + } + + + @Override + public String toString() { + return "[name=randomRuin][fraction="+fractionOfAllNodes2beRuined+"]"; + } + + private Job pickRandomJob(LinkedList availableJobs) { + int randomIndex = random.nextInt(availableJobs.size()); + return availableJobs.get(randomIndex); + } + + private int selectNuOfJobs2BeRemoved() { + return (int) Math.ceil(vrp.getJobs().values().size() * fractionOfAllNodes2beRuined); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/RuinStrategy.java b/jsprit-core/src/main/java/algorithms/RuinStrategy.java new file mode 100644 index 00000000..67cf868a --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RuinStrategy.java @@ -0,0 +1,47 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; +import java.util.List; + +import basics.Job; +import basics.route.VehicleRoute; + + + + +/** + * + * @author stefan schroeder + * + */ + +interface RuinStrategy { + + public static interface RuinListener { + + } + + /** + * Ruins a current solution, i.e. removes jobs from service providers and + * returns a collection of these removed, and thus unassigned, jobs. + * + * @param vehicleRoutes + * @return + */ + public Collection ruin(Collection vehicleRoutes); + + public Collection ruin(Collection vehicleRoutes, Job targetJob, int nOfJobs2BeRemoved); + +} diff --git a/jsprit-core/src/main/java/algorithms/RuinStrategyFactory.java b/jsprit-core/src/main/java/algorithms/RuinStrategyFactory.java new file mode 100644 index 00000000..3d7bb19a --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/RuinStrategyFactory.java @@ -0,0 +1,29 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.VehicleRoutingProblem; + +interface RuinStrategyFactory { + + public RuinStrategy createStrategy(VehicleRoutingProblem vrp); + +} diff --git a/jsprit-core/src/main/java/algorithms/SchrimpfFactory.java b/jsprit-core/src/main/java/algorithms/SchrimpfFactory.java new file mode 100644 index 00000000..3142c4f4 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/SchrimpfFactory.java @@ -0,0 +1,65 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.net.URL; + +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.io.AlgorithmConfig; +import basics.io.AlgorithmConfigXmlReader; + + +/** + * Factory that creates the {@link VehicleRoutingAlgorithm} as proposed by Schrimpf et al., 2000 with the following parameters: + * + *

+ * R&R_random (prob=0.5, F=0.5); + * R&R_radial (prob=0.5, F=0.3); + * threshold-accepting with exponentialDecayFunction (alpha=0.1, warmup-iterations=100); + * nuOfIterations=2000 + * + *

Gerhard Schrimpf, Johannes Schneider, Hermann Stamm- Wilbrandt, and Gunter Dueck. + * Record breaking optimization results using the ruin and recreate principle. + * Journal of Computational Physics, 159(2):139 – 171, 2000. ISSN 0021-9991. doi: 10.1006/jcph.1999. 6413. + * URL http://www.sciencedirect.com/science/article/ pii/S0021999199964136 + * + *

algorithm-xml-config is available at src/main/resources/schrimpf.xml. + * + * @author stefan schroeder + * + */ +public class SchrimpfFactory { + + /** + * Creates the {@link VehicleRoutingAlgorithm}. + * + * @param vrp + * @return algorithm + */ + public VehicleRoutingAlgorithm createAlgorithm(VehicleRoutingProblem vrp){ + AlgorithmConfig algorithmConfig = new AlgorithmConfig(); + URL resource = this.getClass().getClassLoader().getResource("schrimpf.xml"); + new AlgorithmConfigXmlReader(algorithmConfig).read(resource.getPath()); + return VehicleRoutingAlgorithms.createAlgorithm(vrp, algorithmConfig); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/ScoredJob.java b/jsprit-core/src/main/java/algorithms/ScoredJob.java new file mode 100644 index 00000000..b4da2991 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/ScoredJob.java @@ -0,0 +1,63 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.route.VehicleRoute; + + + +class ScoredJob { + + private final Job job; + + private final double score; + + private final InsertionData insertionData; + + private final VehicleRoute route; + + public ScoredJob(final Job job, final double score, final InsertionData insertionData, final VehicleRoute route) { + super(); + this.job = job; + this.score = score; + this.insertionData = insertionData; + this.route = route; + } + + public InsertionData getInsertionData() { + return insertionData; + } + + public VehicleRoute getRoute() { + return route; + } + + public Job getJob() { + return job; + } + + public double getScore() { + return score; + } + + +} diff --git a/jsprit-core/src/main/java/algorithms/SolutionVerifier.java b/jsprit-core/src/main/java/algorithms/SolutionVerifier.java new file mode 100644 index 00000000..69566285 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/SolutionVerifier.java @@ -0,0 +1,51 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; +import java.util.HashSet; +import java.util.Set; + +import basics.Job; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmEndsListener; +import basics.route.VehicleRoute; + +class SolutionVerifier implements AlgorithmEndsListener{ + + @Override + public void informAlgorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + + for(VehicleRoutingProblemSolution solution : solutions){ + Set jobsInSolution = new HashSet(); + for(VehicleRoute route : solution.getRoutes()){ + jobsInSolution.addAll(route.getTourActivities().getJobs()); + } + if(jobsInSolution.size() != problem.getJobs().size()){ + throw new IllegalStateException("we are at the end of the algorithm and still have not found a valid solution." + + "This cannot be."); + } + } + + } + +} diff --git a/jsprit-core/src/main/java/algorithms/TourConstraintEngine.java b/jsprit-core/src/main/java/algorithms/TourConstraintEngine.java new file mode 100644 index 00000000..6cd3e758 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/TourConstraintEngine.java @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.Job; +import basics.route.VehicleRoute; + +class TourConstraintEngine { + +// void ini(VehicleRoute route, Job job){ +// +// } +// + + +} diff --git a/jsprit-core/src/main/java/algorithms/TourStateUpdater.java b/jsprit-core/src/main/java/algorithms/TourStateUpdater.java new file mode 100644 index 00000000..b46af2ec --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/TourStateUpdater.java @@ -0,0 +1,91 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.apache.log4j.Logger; + +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.VehicleRoute; + + + + + +/** + * Updates tour state, i.e. the tour as well as each activity in that tour has a state such as currentLoad, currentCost, earliestOperationTime and + * latestOperationTime. Each time the tour is changed (for instance by removing or adding an activity), tour and activity states + * might change, thus this updater updates activity states. + * This includes: + * - update load and totalCost at tour-level + * - update currentLoad and currentCost at activity-level + * - update earliest- and latestOperationStart values at activity-level + * + * If ensureFeasibility is true, then it additionally checks whether the earliestOperationStartTime is higher than the latestOperationStartTime. + * If it is, it returns a false value to indicate that the tour is not feasible. This makes only sense for hard-timewindows. + * + * If softTimeWindow is set to true, latestOperationStartTimes are not updated and the tour is always feasible. + * + * @author stefan schroeder + * + */ + +class TourStateUpdater implements VehicleRouteUpdater{ + +// public final static Counter counter = new Counter("#updateTWProcesses: "); + + private static Logger logger = Logger.getLogger(TourStateUpdater.class); + + private boolean ensureFeasibility = true; + + private UpdateTourStatesForwardInTime forwardUpdate; + + private UpdateTourStatesBackwardInTime backwardUpdate; + + private boolean updateTimeWindows = true; + + private RouteStates actStates; + + public TourStateUpdater(RouteStates activityStates, VehicleRoutingTransportCosts costs, VehicleRoutingActivityCosts costFunction) { + super(); + forwardUpdate = new UpdateTourStatesForwardInTime(costs, costs, costFunction); + backwardUpdate = new UpdateTourStatesBackwardInTime(costs); + actStates=activityStates; + forwardUpdate.setActivityStates(actStates); + backwardUpdate.setActivityStates(actStates); + } + + /* + * + */ + public boolean updateRoute(VehicleRoute vehicleRoute) { + if(updateTimeWindows){ + backwardUpdate.checkFeasibility = ensureFeasibility; + backwardUpdate.updateRoute(vehicleRoute); + } + forwardUpdate.updateRoute(vehicleRoute); + boolean tourIsFeasible = true; + + return tourIsFeasible; + } + + public void setTimeWindowUpdate(boolean updateTimeWindows) { + this.updateTimeWindows = updateTimeWindows; + logger.info("set timeWindowUpdate to " + updateTimeWindows); + } + + public void setEnsureFeasibility(boolean ensureFeasibility) { + this.ensureFeasibility = ensureFeasibility; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/UpdateTourStatesBackwardInTime.java b/jsprit-core/src/main/java/algorithms/UpdateTourStatesBackwardInTime.java new file mode 100644 index 00000000..19a8d5e3 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/UpdateTourStatesBackwardInTime.java @@ -0,0 +1,105 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Iterator; + +import org.apache.log4j.Logger; + +import algorithms.RouteStates.ActivityState; +import basics.costs.BackwardTransportTime; +import basics.route.Start; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.VehicleRoute; + + + + + + +/** + * + * @author stefan schroeder + * + */ + +class UpdateTourStatesBackwardInTime implements VehicleRouteUpdater{ + +// public static Counter counter = new Counter("#updateTWProcesses: "); + + private static Logger log = Logger.getLogger(UpdateTourStatesBackwardInTime.class); + + public boolean checkFeasibility = true; + + private BackwardTransportTime transportTime; + + private RouteStates actStates; + + public void setActivityStates(RouteStates actStates){ + this.actStates = actStates; + } + + public ActivityState state(TourActivity act){ + return actStates.getState(act); + } + + public UpdateTourStatesBackwardInTime(BackwardTransportTime transportTime) { + super(); + this.transportTime = transportTime; + } + + /* + * + */ + public boolean updateRoute(VehicleRoute vehicleRoute) { + boolean ok = update(vehicleRoute); + return ok; + } + + + + private boolean update(VehicleRoute vehicleRoute) { + TourActivities tour = vehicleRoute.getTourActivities(); + int tourSize = tour.getActivities().size(); + Iterator reverseActIter = vehicleRoute.getTourActivities().reverseActivityIterator(); + TourActivity prevAct; + boolean feasible = true; + prevAct = vehicleRoute.getEnd(); + double startAtPrevAct = prevAct.getTheoreticalLatestOperationStartTime(); + int count = 0; + while(reverseActIter.hasNext()){ + TourActivity currAct = reverseActIter.next(); + + double latestOperationStartTime = latestOperationStartTime(vehicleRoute, prevAct, currAct, startAtPrevAct); + ActivityState state = state(currAct); + state.setLatestOperationStart(latestOperationStartTime); + prevAct = currAct; + startAtPrevAct = latestOperationStartTime; + count++; + } +// Start start = vehicleRoute.getStart(); +// double latestOperationStartTime = latestOperationStartTime(vehicleRoute, prevAct, start, startAtPrevAct); + assert count == tourSize; + return feasible; + } + + private double latestOperationStartTime(VehicleRoute vehicleRoute, + TourActivity prevAct, TourActivity currAct, double startAtPrevAct) { + double latestDepTimeAtCurrAct = startAtPrevAct - transportTime.getBackwardTransportTime(currAct.getLocationId(), prevAct.getLocationId(), startAtPrevAct, vehicleRoute.getDriver(),vehicleRoute.getVehicle()); + double potentialLatestOperationStartTimeAtCurrAct = latestDepTimeAtCurrAct - currAct.getOperationTime(); + double latestOperationStartTime = Math.min(currAct.getTheoreticalLatestOperationStartTime(), potentialLatestOperationStartTimeAtCurrAct); + return latestOperationStartTime; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/UpdateTourStatesForwardInTime.java b/jsprit-core/src/main/java/algorithms/UpdateTourStatesForwardInTime.java new file mode 100644 index 00000000..96732e5c --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/UpdateTourStatesForwardInTime.java @@ -0,0 +1,156 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.apache.log4j.Logger; + +import algorithms.RouteStates.ActivityState; +import basics.costs.ForwardTransportCost; +import basics.costs.ForwardTransportTime; +import basics.costs.VehicleRoutingActivityCosts; +import basics.route.Driver; +import basics.route.End; +import basics.route.ServiceActivity; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + +/** + * + * @author sschroeder + * + */ + +class UpdateTourStatesForwardInTime implements VehicleRouteUpdater{ + +// public static Counter counter = new Counter("#updateTWProcesses: "); + private static Logger log = Logger.getLogger(UpdateTourStatesForwardInTime.class); + + public boolean checkFeasibility = true; + + private VehicleRoutingActivityCosts activityCost; + + private ForwardTransportTime transportTime; + + private ForwardTransportCost transportCost; + + private RouteStates routeStates; + + private boolean activityStatesSet = false; + + public void setActivityStates(RouteStates actStates){ + this.routeStates = actStates; + activityStatesSet = true; + } + + public ActivityState state(TourActivity act){ + return routeStates.getState(act); + } + + public UpdateTourStatesForwardInTime(ForwardTransportTime transportTime, ForwardTransportCost transportCost, VehicleRoutingActivityCosts activityCost) { + super(); + this.transportTime = transportTime; + this.transportCost = transportCost; + this.activityCost = activityCost; + } + + /** + * + * + */ + public boolean updateRoute(VehicleRoute vehicleRoute) { + vehicleRoute.getVehicleRouteCostCalculator().reset(); + + Vehicle vehicle = vehicleRoute.getVehicle(); + Driver driver = vehicleRoute.getDriver(); + + TourActivity prevAct = vehicleRoute.getStart(); + + double startAtPrevAct = vehicleRoute.getStart().getEndTime(); + + double totalOperationCost = 0.0; + int totalLoadPicked = 0; + int currentLoadState = 0; + + for(TourActivity currentAct : vehicleRoute.getTourActivities().getActivities()){ + totalLoadPicked += getPickedLoad(currentAct); + currentLoadState += getCapDemand(currentAct); + + double transportTime = this.transportTime.getTransportTime(prevAct.getLocationId(), currentAct.getLocationId(), startAtPrevAct, driver, vehicle); + + double arrivalTimeAtCurrAct = startAtPrevAct + transportTime; + double operationStartTime = Math.max(currentAct.getTheoreticalEarliestOperationStartTime(), arrivalTimeAtCurrAct); + + double operationEndTime = operationStartTime + currentAct.getOperationTime(); + + currentAct.setArrTime(arrivalTimeAtCurrAct); + currentAct.setEndTime(operationEndTime); + + double transportCost = this.transportCost.getTransportCost(prevAct.getLocationId(), currentAct.getLocationId(), startAtPrevAct, driver, vehicle); + double actCost = activityCost.getActivityCost(currentAct, arrivalTimeAtCurrAct, driver, vehicle); + + vehicleRoute.getVehicleRouteCostCalculator().addTransportCost(transportCost); + vehicleRoute.getVehicleRouteCostCalculator().addActivityCost(actCost); + + totalOperationCost += transportCost; + totalOperationCost += actCost; + + if(activityStatesSet){ + ActivityState currentState = state(currentAct); + currentState.setEarliestOperationStart(operationStartTime); + currentState.setCurrentLoad(currentLoadState); + currentState.setCurrentCost(totalOperationCost); + } + + prevAct = currentAct; + startAtPrevAct = operationEndTime; + } + + End currentAct = vehicleRoute.getEnd(); + double transportCost = this.transportCost.getTransportCost(prevAct.getLocationId(), currentAct.getLocationId(), startAtPrevAct, driver, vehicle); + double transportTime = this.transportTime.getTransportTime(prevAct.getLocationId(), currentAct.getLocationId(), startAtPrevAct, driver, vehicle); + double arrivalTimeAtCurrAct = startAtPrevAct + transportTime; + + currentAct.setArrTime(arrivalTimeAtCurrAct); + currentAct.setEndTime(arrivalTimeAtCurrAct); + + totalOperationCost += transportCost; + + routeStates.getRouteState(vehicleRoute).setCosts(totalOperationCost); + routeStates.getRouteState(vehicleRoute).setLoad(totalLoadPicked); + + vehicleRoute.getVehicleRouteCostCalculator().addTransportCost(transportCost); + + vehicleRoute.getVehicleRouteCostCalculator().price(vehicleRoute.getDriver()); + vehicleRoute.getVehicleRouteCostCalculator().price(vehicleRoute.getVehicle()); + vehicleRoute.getVehicleRouteCostCalculator().finish(); + return true; + } + + private int getCapDemand(TourActivity currentAct) { + return currentAct.getCapacityDemand(); + } + + private double getPickedLoad(TourActivity currentAct) { + if(currentAct instanceof ServiceActivity){ + return currentAct.getCapacityDemand(); + } +// else if(currentAct instanceof Pickup){ +// return currentAct.getCapacityDemand(); +// } + return 0.0; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/VehicleFleetManager.java b/jsprit-core/src/main/java/algorithms/VehicleFleetManager.java new file mode 100644 index 00000000..afe104f0 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/VehicleFleetManager.java @@ -0,0 +1,91 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.Collection; + +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; + +interface VehicleFleetManager { + + public static class TypeKey { + + public final VehicleType type; + public final String locationId; + + public TypeKey(VehicleType type, String locationId) { + super(); + this.type = type; + this.locationId = locationId; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((locationId == null) ? 0 : locationId.hashCode()); + result = prime * result + ((type == null) ? 0 : type.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + TypeKey other = (TypeKey) obj; + if (locationId == null) { + if (other.locationId != null) + return false; + } else if (!locationId.equals(other.locationId)) + return false; + if (type == null) { + if (other.type != null) + return false; + } else if (!type.equals(other.type)) + return false; + return true; + } + + + } + + public abstract Vehicle getEmptyVehicle(TypeKey typeId); + + public abstract Collection getAvailableVehicleTypes(); + + public abstract void lock(Vehicle vehicle); + + public abstract void unlock(Vehicle vehicle); + + public abstract Collection getAvailableVehicleTypes(TypeKey withoutThisType); + + public abstract boolean isLocked(Vehicle vehicle); + + public abstract void unlockAll(); + +} diff --git a/jsprit-core/src/main/java/algorithms/VehicleFleetManagerImpl.java b/jsprit-core/src/main/java/algorithms/VehicleFleetManagerImpl.java new file mode 100644 index 00000000..a6f30556 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/VehicleFleetManagerImpl.java @@ -0,0 +1,247 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import org.apache.log4j.Logger; + +import basics.route.Vehicle; +import basics.route.VehicleImpl.NoVehicle; + + + +class VehicleFleetManagerImpl implements VehicleFleetManager { + + public VehicleFleetManagerImpl newInstance(Collection vehicles){ + return new VehicleFleetManagerImpl(vehicles); + } + + public static VehicleFleetManager createDefaultFleetManager() { + return new DefaultFleetManager(); + } + + public static class DefaultFleetManager extends VehicleFleetManagerImpl { + + public DefaultFleetManager() { + super(Collections.EMPTY_LIST); + + } + + } + + static class TypeContainer { + + private TypeKey type; + + private ArrayList vehicleList; + + public TypeContainer(TypeKey type) { + super(); + this.type = type; + vehicleList = new ArrayList(); + } + + void add(Vehicle vehicle){ + if(vehicleList.contains(vehicle)){ + throw new IllegalStateException("cannot add vehicle twice " + vehicle.getId()); + } + vehicleList.add(vehicle); + } + + void remove(Vehicle vehicle){ + vehicleList.remove(vehicle); + } + + public Vehicle getVehicle() { + return vehicleList.get(0); +// return vehicleList.getFirst(); + } + + public boolean isEmpty() { + return vehicleList.isEmpty(); + } + + } + + private static Logger logger = Logger.getLogger(VehicleFleetManagerImpl.class); + + private Collection vehicles; + + private Set lockedVehicles; + + private Map typeMapOfAvailableVehicles; + + public VehicleFleetManagerImpl(Collection vehicles) { + super(); + this.vehicles = vehicles; + this.lockedVehicles = new HashSet(); + makeMap(); + logger.info("initialise " + this); + } + + public VehicleFleetManagerImpl(Collection vehicles, Collection lockedVehicles) { + this.vehicles = vehicles; + makeMap(); + this.lockedVehicles = new HashSet(); + for(Vehicle v : lockedVehicles){ + lock(v); + } + logger.info("initialise " + this); + } + + @Override + public String toString() { + return "[name=finiteVehicles]"; + } + + private void makeMap() { + typeMapOfAvailableVehicles = new HashMap(); + for(Vehicle v : vehicles){ + addVehicle(v); + } + } + + private void addVehicle(Vehicle v) { + if(v.getType() == null){ + throw new IllegalStateException("vehicle needs type"); + } +// String typeId = v.getType().typeId; + TypeKey typeKey = new TypeKey(v.getType(),v.getLocationId()); + if(!typeMapOfAvailableVehicles.containsKey(typeKey)){ + typeMapOfAvailableVehicles.put(typeKey, new TypeContainer(typeKey)); + } + typeMapOfAvailableVehicles.get(typeKey).add(v); + } + + private void removeVehicle(Vehicle v){ + TypeKey key = new TypeKey(v.getType(),v.getLocationId()); + if(typeMapOfAvailableVehicles.containsKey(key)){ + typeMapOfAvailableVehicles.get(key).remove(v); + } + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#getEmptyVehicle(java.lang.String) + */ + @Override + public Vehicle getEmptyVehicle(TypeKey typeId){ + Vehicle v = null; + if(typeMapOfAvailableVehicles.containsKey(typeId)){ + v = typeMapOfAvailableVehicles.get(typeId).getVehicle(); + } + return v; + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#getAvailableVehicleTypes() + */ + @Override + public Collection getAvailableVehicleTypes(){ + List types = new ArrayList(); + for(TypeKey key : typeMapOfAvailableVehicles.keySet()){ + if(!typeMapOfAvailableVehicles.get(key).isEmpty()){ + types.add(key); + } + } + return types; + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#lock(org.matsim.contrib.freight.vrp.basics.Vehicle) + */ + @Override + public void lock(Vehicle vehicle){ + if(vehicles.isEmpty() || vehicle instanceof NoVehicle){ + return; + } + boolean locked = lockedVehicles.add(vehicle); + removeVehicle(vehicle); + if(!locked){ + throw new IllegalStateException("cannot lock vehicle twice " + vehicle.getId()); + } + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#unlock(org.matsim.contrib.freight.vrp.basics.Vehicle) + */ + @Override + public void unlock(Vehicle vehicle){ + if(vehicles.isEmpty() || vehicle instanceof NoVehicle){ + return; + } + if(vehicle == null) return; + lockedVehicles.remove(vehicle); + addVehicle(vehicle); + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#getAvailableVehicleTypes(java.lang.String) + */ + @Override + public Collection getAvailableVehicleTypes(TypeKey withoutThisType) { + List types = new ArrayList(); + for(TypeKey typeKey : typeMapOfAvailableVehicles.keySet()){ + if(typeKey.equals(withoutThisType)){ + continue; + } + if(!typeMapOfAvailableVehicles.get(typeKey).isEmpty()){ + types.add(typeKey); + } + } + return types; + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#isLocked(org.matsim.contrib.freight.vrp.basics.Vehicle) + */ + @Override + public boolean isLocked(Vehicle vehicle) { + return lockedVehicles.contains(vehicle); + } + + /* (non-Javadoc) + * @see org.matsim.contrib.freight.vrp.basics.VehicleFleetManager#unlockAll() + */ + @Override + public void unlockAll() { + Collection locked = new ArrayList(lockedVehicles); + for(Vehicle v : locked){ + unlock(v); + } + if(!lockedVehicles.isEmpty()){ + throw new IllegalStateException("no vehicle must be locked"); + } + } + + public int sizeOfLockedVehicles(){ + return lockedVehicles.size(); + } + + +} diff --git a/jsprit-core/src/main/java/algorithms/VehicleRouteUpdater.java b/jsprit-core/src/main/java/algorithms/VehicleRouteUpdater.java new file mode 100644 index 00000000..ab0efa4e --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/VehicleRouteUpdater.java @@ -0,0 +1,29 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.route.VehicleRoute; + + +/** + * Updater that updates a vehicleRoute, e.g. the total costs or the time-windows. + * + * @author stefan schroeder + * + */ + +interface VehicleRouteUpdater { + + public boolean updateRoute(VehicleRoute vehicleRoute); + +} diff --git a/jsprit-core/src/main/java/algorithms/VehicleRoutingAlgorithms.java b/jsprit-core/src/main/java/algorithms/VehicleRoutingAlgorithms.java new file mode 100644 index 00000000..302a2ff7 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/VehicleRoutingAlgorithms.java @@ -0,0 +1,870 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import org.apache.commons.configuration.HierarchicalConfiguration; +import org.apache.commons.configuration.XMLConfiguration; +import org.apache.log4j.Logger; + +import util.RouteUtils; +import algorithms.VehicleRoutingAlgorithms.TypedMap.AbstractInsertionKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.AbstractKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.AcceptorKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.RuinStrategyKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.SelectorKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.StrategyModuleKey; +import algorithms.acceptors.AcceptNewIfBetterThanWorst; +import algorithms.acceptors.AcceptNewRemoveFirst; +import algorithms.acceptors.SchrimpfAcceptance; +import algorithms.acceptors.SolutionAcceptor; +import algorithms.selectors.SelectBest; +import algorithms.selectors.SelectRandomly; +import algorithms.selectors.SolutionSelector; +import basics.Job; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmStartsListener; +import basics.algo.InsertionListener; +import basics.algo.SearchStrategy; +import basics.algo.SearchStrategyManager; +import basics.algo.SearchStrategyModule; +import basics.algo.SearchStrategyModuleListener; +import basics.algo.VehicleRoutingAlgorithmListeners.PrioritizedVRAListener; +import basics.algo.VehicleRoutingAlgorithmListeners.Priority; +import basics.io.AlgorithmConfig; +import basics.io.AlgorithmConfigXmlReader; +import basics.route.VehicleRoute; + + + +public class VehicleRoutingAlgorithms { + + static class TypedMap { + + static interface AbstractKey { + + Class getType(); + } + + static class AcceptorKey implements AbstractKey{ + + private ModKey modKey; + + public AcceptorKey(ModKey modKey) { + super(); + this.modKey = modKey; + } + + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((modKey == null) ? 0 : modKey.hashCode()); + return result; + } + + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (!(obj instanceof AcceptorKey)) + return false; + AcceptorKey other = (AcceptorKey) obj; + if (modKey == null) { + if (other.modKey != null) + return false; + } else if (!modKey.equals(other.modKey)) + return false; + return true; + } + + + @Override + public Class getType() { + return SolutionAcceptor.class; + } + + } + + static class SelectorKey implements AbstractKey{ + + private ModKey modKey; + + public SelectorKey(ModKey modKey) { + super(); + this.modKey = modKey; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((modKey == null) ? 0 : modKey.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + SelectorKey other = (SelectorKey) obj; + if (modKey == null) { + if (other.modKey != null) + return false; + } else if (!modKey.equals(other.modKey)) + return false; + return true; + } + + + + @Override + public Class getType() { + return SolutionSelector.class; + } + + } + + static class StrategyModuleKey implements AbstractKey{ + + private ModKey modKey; + + public StrategyModuleKey(ModKey modKey) { + super(); + this.modKey = modKey; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((modKey == null) ? 0 : modKey.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + StrategyModuleKey other = (StrategyModuleKey) obj; + if (modKey == null) { + if (other.modKey != null) + return false; + } else if (!modKey.equals(other.modKey)) + return false; + return true; + } + + + + @Override + public Class getType() { + return SearchStrategyModule.class; + } + + } + + static class RuinStrategyKey implements AbstractKey{ + + private ModKey modKey; + + public RuinStrategyKey(ModKey modKey) { + super(); + this.modKey = modKey; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((modKey == null) ? 0 : modKey.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + RuinStrategyKey other = (RuinStrategyKey) obj; + if (modKey == null) { + if (other.modKey != null) + return false; + } else if (!modKey.equals(other.modKey)) + return false; + return true; + } + + + + @Override + public Class getType() { + return RuinStrategy.class; + } + + } + + static class AbstractInsertionKey implements AbstractKey{ + + private ModKey modKey; + + public AbstractInsertionKey(ModKey modKey) { + super(); + this.modKey = modKey; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((modKey == null) ? 0 : modKey.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + AbstractInsertionKey other = (AbstractInsertionKey) obj; + if (modKey == null) { + if (other.modKey != null) + return false; + } else if (!modKey.equals(other.modKey)) + return false; + return true; + } + + + + @Override + public Class getType() { + return AbstractInsertionStrategy.class; + } + + } + + private Map, Object> map = new HashMap, Object>(); + + public T get(AbstractKey key) { + if(map.get(key) == null) return null; + return key.getType().cast(map.get(key)); + } + + public T put(AbstractKey key, T value) { + return key.getType().cast(map.put(key, key.getType().cast(value))); + } + + public Set> keySet(){ + return map.keySet(); + } + } + + static class ModKey { + private String name; + private String id; + + public ModKey(String name, String id) { + super(); + this.name = name; + this.id = id; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((id == null) ? 0 : id.hashCode()); + result = prime * result + ((name == null) ? 0 : name.hashCode()); + return result; + } + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + ModKey other = (ModKey) obj; + if (id == null) { + if (other.id != null) + return false; + } else if (!id.equals(other.id)) + return false; + if (name == null) { + if (other.name != null) + return false; + } else if (!name.equals(other.name)) + return false; + return true; + } + + } + + private static Logger log = Logger.getLogger(VehicleRoutingAlgorithms.class); + + private VehicleRoutingAlgorithms(){} + + public static VehicleRoutingAlgorithm createAlgorithm(final VehicleRoutingProblem vrp, final AlgorithmConfig algorithmConfig){ + return createAlgo(vrp,algorithmConfig.getXMLConfiguration()); + } + + @Deprecated + public static VehicleRoutingAlgorithm readAndCreateAlgorithm(final VehicleRoutingProblem vrp, final XMLConfiguration config){ + return createAlgo(vrp,config); + } + + public static VehicleRoutingAlgorithm readAndCreateAlgorithm(final VehicleRoutingProblem vrp, final String configFileName){ + AlgorithmConfig algorithmConfig = new AlgorithmConfig(); + AlgorithmConfigXmlReader xmlReader = new AlgorithmConfigXmlReader(algorithmConfig); + xmlReader.read(configFileName); + return createAlgo(vrp,algorithmConfig.getXMLConfiguration()); + } + + private static VehicleRoutingAlgorithm createAlgo(final VehicleRoutingProblem vrp, XMLConfiguration config){ + + //fleetmanager + final VehicleFleetManager vehicleFleetManager; + if(vrp.getFleetSize().equals(FleetSize.INFINITE)){ + vehicleFleetManager = new InfiniteVehicles(vrp.getVehicles()); + + } + else if(vrp.getFleetSize().equals(FleetSize.FINITE)){ + vehicleFleetManager = new VehicleFleetManagerImpl(vrp.getVehicles()); + } + else{ + throw new IllegalStateException("fleet size can only be infinite or finite. " + + "makes sure your config file contains one of these options"); + } + + Set algorithmListeners = new HashSet(); + List insertionListeners = new ArrayList(); + + algorithmListeners.add(new PrioritizedVRAListener(Priority.LOW, new SolutionVerifier())); + + RouteStates routeStates = new RouteStates(); + routeStates.initialiseStateOfJobs(vrp.getJobs().values()); + algorithmListeners.add(new PrioritizedVRAListener(Priority.LOW, routeStates)); + + TypedMap definedClasses = new TypedMap(); + + /* + * initial solution - construction + */ + AlgorithmStartsListener createInitialSolution = createInitialSolution(config,vrp,vehicleFleetManager,routeStates,algorithmListeners,definedClasses); + if(createInitialSolution != null) algorithmListeners.add(new PrioritizedVRAListener(Priority.MEDIUM, createInitialSolution)); + + int solutionMemory = config.getInt("strategy.memory"); + SearchStrategyManager searchStratManager = new SearchStrategyManager(); + List strategyConfigs = config.configurationsAt("strategy.searchStrategies.searchStrategy"); + for(HierarchicalConfiguration strategyConfig : strategyConfigs){ + String name = getName(strategyConfig); + SolutionAcceptor acceptor = getAcceptor(strategyConfig,vrp,algorithmListeners,definedClasses,solutionMemory); + SolutionSelector selector = getSelector(strategyConfig,vrp,algorithmListeners,definedClasses); + SearchStrategy strategy = new SearchStrategy(selector, acceptor); + strategy.setName(name); + List modulesConfig = strategyConfig.configurationsAt("modules.module"); + for(HierarchicalConfiguration moduleConfig : modulesConfig){ + SearchStrategyModule module = buildModule(moduleConfig,vrp,vehicleFleetManager,routeStates,algorithmListeners,definedClasses); + strategy.addModule(module); + } + searchStratManager.addStrategy(strategy, strategyConfig.getDouble("probability")); + } + VehicleRoutingAlgorithm metaAlgorithm = new VehicleRoutingAlgorithm(vrp, searchStratManager); + if(config.containsKey("iterations")){ + metaAlgorithm.setNuOfIterations(config.getInt("iterations")); + } + registerListeners(metaAlgorithm,algorithmListeners); + registerInsertionListeners(definedClasses,insertionListeners); + return metaAlgorithm; + } + + private static void registerInsertionListeners(TypedMap definedClasses, List insertionListeners) { + for(AbstractKey key : definedClasses.keySet()){ + if(key instanceof AbstractInsertionKey){ + AbstractInsertionKey insertionKey = (AbstractInsertionKey) key; + AbstractInsertionStrategy insertionStrategy = definedClasses.get(insertionKey); + for(InsertionListener l : insertionListeners){ + // log.info("add insertionListener " + l + " to " + insertionStrategy); + insertionStrategy.addListener(l); + } + } + } + // log.warn("cannot register insertion listeners yet"); + } + + private static String getName(HierarchicalConfiguration strategyConfig) { + if(strategyConfig.containsKey("[@name]")){ + return strategyConfig.getString("[@name]"); + } + return ""; + } + + + private static void registerListeners(VehicleRoutingAlgorithm metaAlgorithm, Set algorithmListeners) { + metaAlgorithm.getAlgorithmListeners().addAll(algorithmListeners); + } + + private static AlgorithmStartsListener createInitialSolution(XMLConfiguration config, final VehicleRoutingProblem vrp, VehicleFleetManager vehicleFleetManager, RouteStates activityStates, Set algorithmListeners, TypedMap definedClasses) { + List modConfigs = config.configurationsAt("construction.insertion"); + if(modConfigs == null) return null; + if(modConfigs.isEmpty()) return null; + if(modConfigs.size() != 1) throw new IllegalStateException("#construction.modules != 1. 1 expected"); + HierarchicalConfiguration modConfig = modConfigs.get(0); + String insertionName = modConfig.getString("[@name]"); + if(insertionName == null) throw new IllegalStateException("insertion[@name] is missing."); + String insertionId = modConfig.getString("[@id]"); + if(insertionId == null) insertionId = "noId"; + ModKey modKey = makeKey(insertionName,insertionId); + AbstractInsertionKey insertionStrategyKey = new AbstractInsertionKey(modKey); + AbstractInsertionStrategy insertionStrategy = definedClasses.get(insertionStrategyKey); + if(insertionStrategy == null){ + List prioListeners = new ArrayList(); + insertionStrategy = createInsertionStrategy(modConfig, vrp, vehicleFleetManager, activityStates, prioListeners); + algorithmListeners.addAll(prioListeners); + definedClasses.put(insertionStrategyKey,insertionStrategy); + } + final AbstractInsertionStrategy finalInsertionStrategy = insertionStrategy; + + return new AlgorithmStartsListener() { + + @Override + public void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + + CreateInitialSolution createInitialSolution = new CreateInitialSolution(finalInsertionStrategy); + createInitialSolution.setGenerateAsMuchAsRoutesAsVehiclesExist(false); + VehicleRoutingProblemSolution vrpSol = createInitialSolution.createInitialSolution(vrp); + solutions.add(vrpSol); + + } + }; + + + } + + private static SolutionSelector getSelector(HierarchicalConfiguration strategyConfig, VehicleRoutingProblem vrp, Set algorithmListeners, TypedMap definedSelectors) { + String selectorName = strategyConfig.getString("selector[@name]"); + if(selectorName == null) throw new IllegalStateException("no solutionSelector defined. define either \"selectRandom\" or \"selectBest\""); + String selectorId = strategyConfig.getString("selector[@id]"); + if(selectorId == null) selectorId="noId"; + ModKey modKey = makeKey(selectorName,selectorId); + SelectorKey selectorKey = new SelectorKey(modKey); + SolutionSelector definedSelector = definedSelectors.get(selectorKey); + if(definedSelector != null) { + return definedSelector; + } + if(selectorName.equals("selectRandom")){ + SelectRandomly selector = SelectRandomly.getInstance(); + definedSelectors.put(selectorKey, selector); + return selector; + } + if(selectorName.equals("selectBest")){ + SelectBest selector = SelectBest.getInstance(); + definedSelectors.put(selectorKey, selector); + return selector; + } + throw new IllegalStateException("solutionSelector is not know. Currently, it only knows \"selectRandom\" and \"selectBest\""); + } + + private static ModKey makeKey(String name, String id){ + return new ModKey(name, id); + } + + private static SolutionAcceptor getAcceptor(HierarchicalConfiguration strategyConfig, VehicleRoutingProblem vrp, Set algorithmListeners, TypedMap typedMap, int solutionMemory) { + String acceptorName = strategyConfig.getString("acceptor[@name]"); + if(acceptorName == null) throw new IllegalStateException("no solution acceptor is defined"); + String acceptorId = strategyConfig.getString("acceptor[@id]"); + if(acceptorId == null) acceptorId = "noId"; + AcceptorKey acceptorKey = new AcceptorKey(makeKey(acceptorName,acceptorId)); + SolutionAcceptor definedAcceptor = typedMap.get(acceptorKey); + if(definedAcceptor != null) return definedAcceptor; + if(acceptorName.equals("acceptNewRemoveWorst")){ + AcceptNewIfBetterThanWorst acceptor = new AcceptNewIfBetterThanWorst(solutionMemory); + typedMap.put(acceptorKey, acceptor); + return acceptor; + } + if(acceptorName.equals("acceptNewRemoveFirst")){ + AcceptNewRemoveFirst acceptor = new AcceptNewRemoveFirst(solutionMemory); + typedMap.put(acceptorKey, acceptor); + return acceptor; + } + if(acceptorName.equals("schrimpfAcceptance")){ + int iterOfSchrimpf = strategyConfig.getInt("acceptor.warmup"); + double alpha = strategyConfig.getDouble("acceptor.alpha"); + SchrimpfAcceptance schrimpf = new SchrimpfAcceptance(solutionMemory, alpha, iterOfSchrimpf); + algorithmListeners.add(new PrioritizedVRAListener(Priority.LOW, schrimpf)); + typedMap.put(acceptorKey, schrimpf); + return schrimpf; + } + else{ + throw new IllegalStateException("solution acceptor " + acceptorName + " is not known"); + } + } + + private static SearchStrategyModule buildModule(HierarchicalConfiguration moduleConfig, VehicleRoutingProblem vrp, VehicleFleetManager vehicleFleetManager, + RouteStates activityStates, Set algorithmListeners, TypedMap definedClasses) { + String moduleName = moduleConfig.getString("[@name]"); + if(moduleName == null) throw new IllegalStateException("module(-name) is missing."); + String moduleId = moduleConfig.getString("[@id]"); + if(moduleId == null) moduleId = "noId"; + ModKey modKey = makeKey(moduleName,moduleId); + StrategyModuleKey strategyModuleKey = new StrategyModuleKey(modKey); + SearchStrategyModule definedModule = definedClasses.get(strategyModuleKey); + if(definedModule != null) return definedModule; + if(moduleName.equals("ruin_and_recreate")){ + String ruin_name = moduleConfig.getString("ruin[@name]"); + if(ruin_name == null) throw new IllegalStateException("module.ruin[@name] is missing."); + String ruin_id = moduleConfig.getString("ruin[@id]"); + if(ruin_id == null) ruin_id = "noId"; + String shareToRuinString = moduleConfig.getString("ruin.share"); + if(shareToRuinString == null) throw new IllegalStateException("module.ruin.share is missing."); + double shareToRuin = Double.valueOf(shareToRuinString); + final RuinStrategy ruin; + ModKey ruinKey = makeKey(ruin_name,ruin_id); + if(ruin_name.equals("randomRuin")){ + ruin = getRandomRuin(vrp, activityStates, definedClasses, ruinKey, shareToRuin); + } + else if(ruin_name.equals("radialRuin")){ + ruin = getRadialRuin(vrp, activityStates, definedClasses, ruinKey, shareToRuin); + } + else throw new IllegalStateException("ruin[@name] " + ruin_name + " is not known. Use either randomRuin or radialRuin."); + + String insertionName = moduleConfig.getString("insertion[@name]"); + if(insertionName == null) throw new IllegalStateException("module.insertion[@name] is missing. set it to \"regretInsertion\" or \"bestInsertion\""); + String insertionId = moduleConfig.getString("insertion[@id]"); + if(insertionId == null) insertionId = "noId"; + ModKey insertionKey = makeKey(insertionName,insertionId); + AbstractInsertionKey insertionStrategyKey = new AbstractInsertionKey(insertionKey); + AbstractInsertionStrategy insertion = definedClasses.get(insertionStrategyKey); + if(insertion == null){ + List insertionConfigs = moduleConfig.configurationsAt("insertion"); + if(insertionConfigs.size() != 1) throw new IllegalStateException("this should be 1"); + List prioListeners = new ArrayList(); + insertion = createInsertionStrategy(insertionConfigs.get(0), vrp, vehicleFleetManager, activityStates, prioListeners); + algorithmListeners.addAll(prioListeners); + } + final AbstractInsertionStrategy final_insertion = insertion; + SearchStrategyModule module = new SearchStrategyModule() { + + private Logger logger = Logger.getLogger(SearchStrategyModule.class); + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + Collection ruinedJobs = ruin.ruin(vrpSolution.getRoutes()); + final_insertion.run(vrpSolution.getRoutes(), ruinedJobs, Double.MAX_VALUE); + double totalCost = RouteUtils.getTotalCost(vrpSolution.getRoutes()); + vrpSolution.setCost(totalCost); + return vrpSolution; + } + + @Override + public String toString() { + return getName(); + } + + @Override + public String getName() { + return "[name=ruin_and_recreate][ruin="+ruin+"][recreate="+final_insertion+"]"; + } + + @Override + public void addModuleListener(SearchStrategyModuleListener moduleListener) { + if(moduleListener instanceof InsertionListener){ + InsertionListener iListener = (InsertionListener) moduleListener; + if(!final_insertion.getListener().contains(iListener)){ + logger.info("register moduleListener " + moduleListener); + final_insertion.addListener(iListener); + } + + } + + } + }; + return module; + } + if(moduleName.equals("bestInsertion") || moduleName.equals("regretInsertion")){ + List prioListeners = new ArrayList(); + AbstractInsertionStrategy insertion = getInsertionStrategy(moduleConfig, vrp, vehicleFleetManager, activityStates, + definedClasses, modKey, prioListeners); + SearchStrategyModule module = getModule(moduleName, insertion, vrp); + definedClasses.put(strategyModuleKey, module); + algorithmListeners.addAll(prioListeners); + return module; + } +// if(moduleName.equals("regretInsertion")){ +// List prioListeners = new ArrayList(); +// AbstractInsertionKey insertionKey = new AbstractInsertionKey(modKey); +// AbstractInsertionStrategy regretInsertion = definedClasses.get(insertionKey); +// if(regretInsertion == null){ +// regretInsertion = createInsertionStrategy(moduleConfig,vrp,vehicleFleetManager,activityStates,prioListeners); +// } +// SearchStrategyModule module = getModule(moduleName, regretInsertion, vrp); +// definedClasses.put(strategyModuleKey, module); +// algorithmListeners.addAll(prioListeners); +// return module; +// } + if(moduleName.equals("randomRuin")){ + double shareToRuin = moduleConfig.getDouble("share"); + RuinStrategy ruin = getRandomRuin(vrp, activityStates,definedClasses, modKey, shareToRuin); + SearchStrategyModule module = getModule(moduleName, ruin); + definedClasses.put(strategyModuleKey, module); + return module; + } + if(moduleName.equals("radialRuin")){ + double shareToRuin = moduleConfig.getDouble("share"); + RuinStrategy ruin = getRadialRuin(vrp, activityStates,definedClasses, modKey, shareToRuin); + SearchStrategyModule module = getModule(moduleName, ruin); + definedClasses.put(strategyModuleKey, module); + return module; + } + if(moduleName.equals("gendreauPostOpt")){ + int iterations = moduleConfig.getInt("iterations"); + double share = moduleConfig.getDouble("share"); + String ruinName = moduleConfig.getString("ruin[@name]"); + if(ruinName == null) throw new IllegalStateException("gendreauPostOpt.ruin[@name] is missing. set it to \"radialRuin\" or \"randomRuin\""); + String ruinId = moduleConfig.getString("ruin[@id]"); + if(ruinId == null) ruinId = "noId"; + ModKey ruinKey = makeKey(ruinName,ruinId); + RuinStrategyKey stratKey = new RuinStrategyKey(ruinKey); + RuinStrategy ruin = definedClasses.get(stratKey); + if(ruin == null){ + ruin = RuinRadial.newInstance(vrp, 0.3, new JobDistanceAvgCosts(vrp.getTransportCosts()), new JobRemoverImpl(), new TourStateUpdater(activityStates, vrp.getTransportCosts(), vrp.getActivityCosts())); + definedClasses.put(stratKey, ruin); + } + + String insertionName = moduleConfig.getString("insertion[@name]"); + if(insertionName == null) throw new IllegalStateException("gendreauPostOpt.insertion[@name] is missing. set it to \"regretInsertion\" or \"bestInsertion\""); + String insertionId = moduleConfig.getString("insertion[@id]"); + if(insertionId == null) insertionId = "noId"; + ModKey insertionKey = makeKey(insertionName,insertionId); + AbstractInsertionKey insertionStrategyKey = new AbstractInsertionKey(insertionKey); + AbstractInsertionStrategy insertion = definedClasses.get(insertionStrategyKey); + if(insertion == null){ + List insertionConfigs = moduleConfig.configurationsAt("insertion"); + if(insertionConfigs.size() != 1) throw new IllegalStateException("this should be 1"); + List prioListeners = new ArrayList(); + insertion = createInsertionStrategy(insertionConfigs.get(0), vrp, vehicleFleetManager, activityStates, prioListeners); + algorithmListeners.addAll(prioListeners); + } + GendreauPostOpt postOpt = new GendreauPostOpt(vrp, ruin, insertion); + postOpt.setShareOfJobsToRuin(share); + postOpt.setNuOfIterations(iterations); + postOpt.setFleetManager(vehicleFleetManager); + definedClasses.put(strategyModuleKey, postOpt); + return postOpt; + } + throw new NullPointerException("no module found with moduleName=" + moduleName + + "\n\tcheck config whether the correct names are used" + + "\n\tcurrently there are following modules available: " + + "\n\tbestInsertion" + + "\n\trandomRuin" + + "\n\tradialRuin" + + "\n\tgendreauPostOpt"); + } + + private static AbstractInsertionStrategy getInsertionStrategy(HierarchicalConfiguration moduleConfig, VehicleRoutingProblem vrp,VehicleFleetManager vehicleFleetManager, + RouteStates activityStates, TypedMap definedClasses, + ModKey modKey, List prioListeners) { + AbstractInsertionKey insertionKey = new AbstractInsertionKey(modKey); + AbstractInsertionStrategy bestInsertion = definedClasses.get(insertionKey); + if(bestInsertion == null){ + bestInsertion = createInsertionStrategy(moduleConfig,vrp,vehicleFleetManager,activityStates,prioListeners); + } + return bestInsertion; + } + + private static RuinStrategy getRadialRuin(VehicleRoutingProblem vrp, + RouteStates activityStates, TypedMap definedClasses, + ModKey modKey, double shareToRuin) { + RuinStrategyKey stratKey = new RuinStrategyKey(modKey); + RuinStrategy ruin = definedClasses.get(stratKey); + if(ruin == null){ + ruin = RuinRadial.newInstance(vrp, shareToRuin, new JobDistanceAvgCosts(vrp.getTransportCosts()), new JobRemoverImpl(), new TourStateUpdater(activityStates, vrp.getTransportCosts(), vrp.getActivityCosts())); + definedClasses.put(stratKey, ruin); + } + return ruin; + } + + private static RuinStrategy getRandomRuin(VehicleRoutingProblem vrp, + RouteStates activityStates, TypedMap definedClasses, + ModKey modKey, double shareToRuin) { + RuinStrategyKey stratKey = new RuinStrategyKey(modKey); + RuinStrategy ruin = definedClasses.get(stratKey); + if(ruin == null){ + ruin = RuinRandom.newInstance(vrp, shareToRuin, new JobRemoverImpl(), new TourStateUpdater(activityStates, vrp.getTransportCosts(), vrp.getActivityCosts())); + definedClasses.put(stratKey, ruin); + } + return ruin; + } + + private static AbstractInsertionStrategy createInsertionStrategy(HierarchicalConfiguration moduleConfig, VehicleRoutingProblem vrp,VehicleFleetManager vehicleFleetManager, RouteStates activityStates, List algorithmListeners) { + AbstractInsertionStrategy insertion = InsertionFactory.createInsertion(vrp, moduleConfig, vehicleFleetManager, activityStates, algorithmListeners); + return insertion; + } + + private static SearchStrategyModule getModule(final String moduleName, final AbstractInsertionStrategy insertion, final VehicleRoutingProblem vrp){ + + return new SearchStrategyModule() { + + private Logger logger = Logger.getLogger(SearchStrategyModule.class); + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + List unassignedJobs = getUnassignedJobs(vrpSolution,vrp); + // logger.info("unassigned: " + unassignedJobs.size()); + insertion.run(vrpSolution.getRoutes(), unassignedJobs, Double.MAX_VALUE); + int jobsInSolution = countJobs(vrpSolution); + double penalty = 0.0; + if(jobsInSolution != vrp.getJobs().values().size()){ + throw new IllegalStateException("solution not valid\n" + "#jobsInSolution=" + jobsInSolution + " #jobsInVrp=" + vrp.getJobs().values().size()); +// logger.warn("solution not valid\n" + "#jobsInSolution=" + jobsInSolution + " #jobsInVrp=" + vrp.getJobs().values().size()); +//// throw new IllegalStateException("solution not valid\n" + +//// "#jobsInSolution=" + jobsInSolution + " #jobsInVrp=" + vrp.getJobs().values().size()); +// logger.warn("a penalty of 1000 is added for each unassigned customer"); +// penalty = (vrp.getJobs().values().size() - jobsInSolution)*1000.0; +// logger.warn("penalty = " + penalty); + } + double totalCost = RouteUtils.getTotalCost(vrpSolution.getRoutes()); + vrpSolution.setCost(totalCost + penalty); + return vrpSolution; + } + + @Override + public String toString() { + return "[name="+insertion+"]"; + } + + private int countJobs(VehicleRoutingProblemSolution vrpSolution) { + int counter = 0; + for(VehicleRoute route : vrpSolution.getRoutes()){ + counter += route.getTourActivities().jobSize(); + } + return counter; + } + + private List getUnassignedJobs(VehicleRoutingProblemSolution vrpSolution,VehicleRoutingProblem vrp) { + List unassignedJobs = new ArrayList(); + for(Job j : vrp.getJobs().values()){ + boolean notAssigned = true; + for(VehicleRoute r : vrpSolution.getRoutes()){ + if(r.getTourActivities().servesJob(j)){ + notAssigned = false; + break; + } + } + if(notAssigned){ + unassignedJobs.add(j); + } + } + return unassignedJobs; + } + + @Override + public String getName() { + return moduleName; + } + + @Override + public void addModuleListener(SearchStrategyModuleListener moduleListener) { + if(moduleListener instanceof InsertionListener){ + InsertionListener iListener = (InsertionListener) moduleListener; + if(!insertion.getListener().contains(iListener)){ + logger.info("register moduleListener " + moduleListener); + insertion.addListener(iListener); + } + + } + + } + }; + + } + + private static SearchStrategyModule getModule(final String moduleName, final RuinStrategy ruin) { + + + return new SearchStrategyModule() { + + private Logger logger = Logger.getLogger(SearchStrategyModule.class); + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + ruin.ruin(vrpSolution.getRoutes()); + return vrpSolution; + } + + @Override + public String toString() { + return "[name="+ruin+"]"; + } + + @Override + public String getName() { + return moduleName; + } + + @Override + public void addModuleListener(SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } + + }; + } + + + +} diff --git a/jsprit-core/src/main/java/algorithms/VehicleSwitched.java b/jsprit-core/src/main/java/algorithms/VehicleSwitched.java new file mode 100644 index 00000000..cd0b6bb4 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/VehicleSwitched.java @@ -0,0 +1,40 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.route.Vehicle; +import algorithms.RouteAlgorithm.VehicleSwitchedListener; + +class VehicleSwitched implements VehicleSwitchedListener{ + + private VehicleFleetManager fleetManager; + + VehicleSwitched(VehicleFleetManager fleetManager){ + this.fleetManager = fleetManager; + } + + @Override + public void vehicleSwitched(Vehicle oldVehicle, Vehicle newVehicle) { + fleetManager.unlock(oldVehicle); + fleetManager.lock(newVehicle); + } + +} diff --git a/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewIfBetterThanWorst.java b/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewIfBetterThanWorst.java new file mode 100644 index 00000000..ec495cd4 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewIfBetterThanWorst.java @@ -0,0 +1,71 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.acceptors; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + + +public class AcceptNewIfBetterThanWorst implements SolutionAcceptor{ + + private final int solutionMemory; + + public AcceptNewIfBetterThanWorst(int solutionMemory){ + this.solutionMemory = solutionMemory; + } + + /** + * Accepts every solution if solution memory allows. If memory occupied, than accepts new solution only if better than the worst in memory. + * Consequently, the worst solution is removed from solutions, and the new solution added. + * + *

Note that this modifies Collection solutions. + */ + @Override + public boolean acceptSolution(Collection solutions, VehicleRoutingProblemSolution newSolution) { + boolean solutionAccepted = false; + if (solutions.size() < solutionMemory) { + solutions.add(newSolution); + solutionAccepted = true; + } else { + VehicleRoutingProblemSolution worstSolution = null; + for (VehicleRoutingProblemSolution s : solutions) { + if (worstSolution == null) worstSolution = s; + else if (s.getCost() > worstSolution.getCost()) worstSolution = s; + } + if(newSolution.getCost() < worstSolution.getCost()){ + solutions.remove(worstSolution); + solutions.add(newSolution); + solutionAccepted = true; + } + } + return solutionAccepted; + } + + @Override + public String toString() { + return "[name=acceptNewRemoveWorst]"; + } + + + + +} diff --git a/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewRemoveFirst.java b/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewRemoveFirst.java new file mode 100644 index 00000000..fabea087 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/acceptors/AcceptNewRemoveFirst.java @@ -0,0 +1,59 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.acceptors; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + + +public class AcceptNewRemoveFirst implements SolutionAcceptor{ + + private final int solutionMemory; + + public AcceptNewRemoveFirst(int solutionMemory){ + this.solutionMemory = solutionMemory; + } + + /** + * Accepts every solution if solution memory allows. If memory occupied, than accepts new solution only if better than the worst in memory. + * Consequently, the worst solution is removed from solutions, and the new solution added. + * + *

Note that this modifies Collection solutions. + */ + @Override + public boolean acceptSolution(Collection solutions, VehicleRoutingProblemSolution newSolution) { + if (solutions.size() >= solutionMemory) { + solutions.remove(solutions.iterator().next()); + } + solutions.add(newSolution); + return true; + } + + @Override + public String toString() { + return "[name=acceptNewRemoveFirst]"; + } + + + + +} diff --git a/jsprit-core/src/main/java/algorithms/acceptors/SchrimpfAcceptance.java b/jsprit-core/src/main/java/algorithms/acceptors/SchrimpfAcceptance.java new file mode 100644 index 00000000..380d63d3 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/acceptors/SchrimpfAcceptance.java @@ -0,0 +1,155 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.acceptors; + +import java.net.URL; +import java.util.Collection; + +import org.apache.commons.math.stat.descriptive.moment.StandardDeviation; +import org.apache.log4j.Logger; + +import util.Solutions; +import algorithms.VehicleRoutingAlgorithms; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmStartsListener; +import basics.algo.IterationEndsListener; +import basics.algo.IterationStartsListener; +import basics.io.AlgorithmConfig; +import basics.io.AlgorithmConfigXmlReader; + + + +public class SchrimpfAcceptance implements SolutionAcceptor, IterationStartsListener, AlgorithmStartsListener{ + + private static Logger logger = Logger.getLogger(SchrimpfAcceptance.class); + + private final double alpha; + + private int nOfTotalIterations = 1000; + + private int currentIteration = 0; + + private double initialThreshold = 0.0; + + private final int nOfRandomWalks; + + private final int solutionMemory; + + + public SchrimpfAcceptance(int solutionMemory, double alpha, int nOfWarmupIterations) { + super(); + this.alpha = alpha; + this.nOfRandomWalks = nOfWarmupIterations; + this.solutionMemory = solutionMemory; + logger.info("initialise " + this); + } + + + + @Override + public boolean acceptSolution(Collection solutions, VehicleRoutingProblemSolution newSolution) { + boolean solutionAccepted = false; + if (solutions.size() < solutionMemory) { + solutions.add(newSolution); + solutionAccepted = true; + } else { + VehicleRoutingProblemSolution worst = null; + double threshold = getThreshold(currentIteration); + for(VehicleRoutingProblemSolution solutionInMemory : solutions){ + if(worst == null) worst = solutionInMemory; + else if(solutionInMemory.getCost() > worst.getCost()) worst = solutionInMemory; + } + if(newSolution.getCost() < worst.getCost() + threshold){ + solutions.remove(worst); + solutions.add(newSolution); + solutionAccepted = true; + } + } + return solutionAccepted; + } + + @Override + public String toString() { + return "[name=schrimpfAcceptanceFunction][alpha="+alpha+"][warmup=" + nOfRandomWalks + "]"; + } + + private double getThreshold(int iteration) { + double scheduleVariable = (double) iteration / (double) nOfTotalIterations; +// logger.debug("iter="+iteration+" totalIter="+nOfTotalIterations+" scheduling="+scheduleVariable); + double currentThreshold = initialThreshold * Math.exp(-Math.log(2) * scheduleVariable / alpha); + return currentThreshold; + } + + + @Override + public void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + reset(); + logger.info("---------------------------------------------------------------------"); + logger.info("prepare schrimpfAcceptanceFunction, i.e. determine initial threshold"); + logger.info("start random-walk (see algorith-config at scr/main/resources/randomWalk.xml)"); + double now = System.currentTimeMillis(); + this.nOfTotalIterations = algorithm.getNuOfIterations(); + + /* + * randomWalk to determine standardDev + */ + final double[] results = new double[nOfRandomWalks]; + + URL resource = this.getClass().getClassLoader().getResource("randomWalk.xml"); + AlgorithmConfig algorithmConfig = new AlgorithmConfig(); + new AlgorithmConfigXmlReader(algorithmConfig).read(resource.getPath()); + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.createAlgorithm(problem, algorithmConfig); + vra.setNuOfIterations(nOfRandomWalks); + vra.getAlgorithmListeners().addListener(new IterationEndsListener() { + + @Override + public void informIterationEnds(int iteration, VehicleRoutingProblem problem, Collection solutions) { + double result = Solutions.getBest(solutions).getCost(); +// logger.info("result="+result); + results[iteration-1] = result; + } + + }); + vra.searchSolutions(); + + StandardDeviation dev = new StandardDeviation(); + double standardDeviation = dev.evaluate(results); + initialThreshold = standardDeviation / 2; + + logger.info("warmup done"); + logger.info("total time: " + ((System.currentTimeMillis()-now)/1000.0) + "s"); + logger.info("initial threshold: " + initialThreshold); + logger.info("---------------------------------------------------------------------"); + + } + + private void reset() { + currentIteration = 0; + } + + @Override + public void informIterationStarts(int i, VehicleRoutingProblem problem, Collection solutions) { + currentIteration = i; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/acceptors/SolutionAcceptor.java b/jsprit-core/src/main/java/algorithms/acceptors/SolutionAcceptor.java new file mode 100644 index 00000000..b82066fd --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/acceptors/SolutionAcceptor.java @@ -0,0 +1,47 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.acceptors; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + +/** + * Acceptor that decides whether the newSolution is accepted or not. + * + * + * @author stefan + * + */ +public interface SolutionAcceptor { + + /** + * Accepts solution or not, and returns true if a new solution has been accepted. + * + *

If the solution is accepted, it is added to solutions, i.e. the solutions-collections is modified. + * + * @param solutions + * @param newSolution + * @return TODO + */ + public boolean acceptSolution(Collection solutions, VehicleRoutingProblemSolution newSolution); + +} diff --git a/jsprit-core/src/main/java/algorithms/selectors/SelectBest.java b/jsprit-core/src/main/java/algorithms/selectors/SelectBest.java new file mode 100644 index 00000000..123337b4 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/selectors/SelectBest.java @@ -0,0 +1,64 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.selectors; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + + + + +public class SelectBest implements SolutionSelector{ + + private static SelectBest selector = null; + + public static SelectBest getInstance(){ + if(selector == null){ + selector = new SelectBest(); + return selector; + } + return selector; + } + + @Override + public VehicleRoutingProblemSolution selectSolution(Collection solutions) { + double minCost = Double.MAX_VALUE; + VehicleRoutingProblemSolution bestSolution = null; + for(VehicleRoutingProblemSolution sol : solutions){ + if(bestSolution == null){ + bestSolution = sol; + minCost = sol.getCost(); + } + else if(sol.getCost() < minCost){ + bestSolution = sol; + minCost = sol.getCost(); + } + } + return bestSolution; + } + + @Override + public String toString() { + return "[name=selectBest]"; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/selectors/SelectRandomly.java b/jsprit-core/src/main/java/algorithms/selectors/SelectRandomly.java new file mode 100644 index 00000000..31c3b31a --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/selectors/SelectRandomly.java @@ -0,0 +1,60 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.selectors; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; +import java.util.Random; + +import basics.VehicleRoutingProblemSolution; + +import util.RandomNumberGeneration; + + + +public class SelectRandomly implements SolutionSelector{ + + private static SelectRandomly selector = null; + + public static SelectRandomly getInstance(){ + if(selector == null){ + selector = new SelectRandomly(); + return selector; + } + return selector; + } + + private Random random = RandomNumberGeneration.getRandom(); + + @Override + public VehicleRoutingProblemSolution selectSolution(Collection solutions) { + if(solutions.isEmpty()) return null; + List solList = new ArrayList(solutions); + int randomIndex = random.nextInt(solutions.size()); + return solList.get(randomIndex); + } + + public void setRandom(Random random) { + this.random = random; + } + +} diff --git a/jsprit-core/src/main/java/algorithms/selectors/SolutionSelector.java b/jsprit-core/src/main/java/algorithms/selectors/SolutionSelector.java new file mode 100644 index 00000000..1b8235d8 --- /dev/null +++ b/jsprit-core/src/main/java/algorithms/selectors/SolutionSelector.java @@ -0,0 +1,32 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.selectors; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + + +public interface SolutionSelector { + + public VehicleRoutingProblemSolution selectSolution(Collection solutions); + +} diff --git a/jsprit-core/src/main/java/basics/Job.java b/jsprit-core/src/main/java/basics/Job.java new file mode 100644 index 00000000..11042921 --- /dev/null +++ b/jsprit-core/src/main/java/basics/Job.java @@ -0,0 +1,22 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +public interface Job { + + public String getId(); + + public int getCapacityDemand(); + + +} diff --git a/jsprit-core/src/main/java/basics/Service.java b/jsprit-core/src/main/java/basics/Service.java new file mode 100644 index 00000000..43ea2d4c --- /dev/null +++ b/jsprit-core/src/main/java/basics/Service.java @@ -0,0 +1,183 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import basics.route.TimeWindow; +import util.Coordinate; + + +public class Service implements Job { + + + + public static class Builder { + + public static Builder newInstance(String id, int size){ + return new Builder(id,size); + } + + private String id; + private String locationId; + private String name = "service"; + private Coordinate coord; + private double serviceTime; + private TimeWindow timeWindow = TimeWindow.newInstance(0.0, Double.MAX_VALUE); + private int demand; + + private Builder(String id, int size) { + super(); + this.id = id; + this.demand = size; + } + + public Builder setName(String name){ + this.name = name; + return this; + } + + public Builder setLocationId(String locationId){ + this.locationId = locationId; + return this; + } + + public Builder setCoord(Coordinate coord){ + this.coord = coord; + return this; + } + + public Builder setServiceTime(double serviceTime){ + this.serviceTime = serviceTime; + return this; + } + + public Builder setTimeWindow(TimeWindow tw){ + this.timeWindow = tw; + return this; + } + + public Service build(){ + if(locationId == null) { + if(coord == null) throw new IllegalStateException("either locationId or a coordinate must be given. But is not."); + locationId = coord.toString(); + } + + return new Service(this); + } + + } + + + private final String id; + + private final String locationId; + + private final String name; + + private final Coordinate coord; + + private final double serviceTime; + + private final TimeWindow timeWindow; + + private final int demand; + + private Service(Builder builder){ + id = builder.id; + locationId = builder.locationId; + coord = builder.coord; + serviceTime = builder.serviceTime; + timeWindow = builder.timeWindow; + demand = builder.demand; + name = builder.name; + } + + @Override + public String getId() { + return id; + } + + public String getLocationId() { + return locationId; + } + + public Coordinate getCoord(){ + return coord; + } + + public double getServiceDuration() { + return serviceTime; + } + + public TimeWindow getTimeWindow(){ + return timeWindow; + } + + @Override + public int getCapacityDemand() { + return demand; + } + + /** + * @return the name + */ + public String getType() { + return name; + } + + @Override + public String toString() { + return "[id=" + id + "][locationId=" + locationId + "][coord="+coord+"][size=" + demand + "][serviceTime=" + serviceTime + "][timeWindow=" + timeWindow + "]"; + } + + /* (non-Javadoc) + * @see java.lang.Object#hashCode() + */ + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((id == null) ? 0 : id.hashCode()); + return result; + } + + /* (non-Javadoc) + * @see java.lang.Object#equals(java.lang.Object) + */ + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + Service other = (Service) obj; + if (id == null) { + if (other.id != null) + return false; + } else if (!id.equals(other.id)) + return false; + return true; + } + + + +} diff --git a/jsprit-core/src/main/java/basics/VehicleRoutingAlgorithm.java b/jsprit-core/src/main/java/basics/VehicleRoutingAlgorithm.java new file mode 100644 index 00000000..b8d3269f --- /dev/null +++ b/jsprit-core/src/main/java/basics/VehicleRoutingAlgorithm.java @@ -0,0 +1,202 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import java.util.ArrayList; +import java.util.Collection; + +import org.apache.log4j.Logger; + +import util.Counter; +import algorithms.acceptors.SolutionAcceptor; +import basics.algo.AlgorithmEndsListener; +import basics.algo.AlgorithmStartsListener; +import basics.algo.IterationEndsListener; +import basics.algo.IterationStartsListener; +import basics.algo.SearchStrategy; +import basics.algo.SearchStrategyManager; +import basics.algo.VehicleRoutingAlgorithmListener; +import basics.algo.VehicleRoutingAlgorithmListeners; + +/** + * Algorithm that solves a {@link VehicleRoutingProblem}. + * + * @author stefan schroeder + * + */ +public class VehicleRoutingAlgorithm { + + public static final int NOBREAK = Integer.MAX_VALUE; + + private static Logger logger = Logger.getLogger(VehicleRoutingAlgorithm.class); + + private VehicleRoutingProblem problem; + + private int nOfIterations = 100; + + private int prematureBreak = NOBREAK; + + private Counter counter = new Counter("iterations "); + + private SearchStrategyManager searchStrategyManager; + + private VehicleRoutingAlgorithmListeners algoListeners = new VehicleRoutingAlgorithmListeners(); + + private Collection initialSolutions; + + public VehicleRoutingAlgorithm(VehicleRoutingProblem problem, SearchStrategyManager searchStrategyManager) { + super(); + this.problem = problem; + this.searchStrategyManager = searchStrategyManager; + initialSolutions = new ArrayList(); + } + + public VehicleRoutingAlgorithm(VehicleRoutingProblem problem, Collection initialSolutions, SearchStrategyManager searchStrategyManager) { + super(); + this.problem = problem; + this.searchStrategyManager = searchStrategyManager; + this.initialSolutions = initialSolutions; + } + + /** + * Adds solution to the collection of initial solutions. + * + * @param solution + */ + public void addInitialSolution(VehicleRoutingProblemSolution solution){ + initialSolutions.add(solution); + } + + /** + * Sets premature break. + * + *

This breaks the algorithm prematurely after the assigned number of iterations without improvement (see input parameter). + * Improvement is what {@link SolutionAcceptor} understands about improvement. Or to put it in other words, the algo breaks prematurely after + * the assigned number of iterations without solution-acceptance. + * + * + * @param iterationsWithoutImprovement + */ + public void setPrematureBreak(int iterationsWithoutImprovement){ + prematureBreak = iterationsWithoutImprovement; + } + + /** + * Gets the {@link SearchStrategyManager}. + * + * @return SearchStrategyManager + */ + public SearchStrategyManager getSearchStrategyManager() { + return searchStrategyManager; + } + + /** + * Runs the vehicle routing algorithm and returns a number of generated solutions. + * + *

The algorithm runs as long as it is specified in nuOfIterations and prematureBreak. In each iteration it selects a searchStrategy according + * to searchStrategyManager and runs the strategy to improve solutions. + *

Note that clients are allowed to observe/listen the algorithm. See {@link VehicleRoutingAlgorithmListener} and its according listeners. + * + * @return Collection the solutions + * @see {@link SearchStrategyManager}, {@link VehicleRoutingAlgorithmListener}, {@link AlgorithmStartsListener}, {@link AlgorithmEndsListener}, {@link IterationStartsListener}, {@link IterationEndsListener} + */ + public Collection searchSolutions(){ + logger.info("------------------------------------------------"); + logger.info("algorithm starts"); + double now = System.currentTimeMillis(); + verify(); + counter.reset(); + Collection solutions = new ArrayList(initialSolutions); + algorithmStarts(problem,solutions); + int iterWithoutImprovement = 0; + logger.info("iterations start"); + for(int i=0;i prematureBreak){ + logger.info("premature break at iteration "+ (i+1)); + break; + } + iterationEnds(i+1,problem,solutions); + } + logger.info("iterations end at " + nOfIterations + " iterations"); + algorithmEnds(problem,solutions); + logger.info("total time: " + ((System.currentTimeMillis()-now)/1000.0) + "s"); + logger.info("done"); + logger.info("------------------------------------------------"); + return solutions; + } + + + private void selectedStrategy(String name, VehicleRoutingProblem problem, Collection solutions) { + algoListeners.selectedStrategy(name,problem, solutions); + } + + /** + * Returns the number of iterations. + * + * @return iterations + */ + public int getNuOfIterations(){ + return nOfIterations; + } + + /** + * Asserts that the sum of probabilities of the searchStrategies is equal to 1.0. + */ + private void verify() { + double sum = 0.0; + for(Double prob : searchStrategyManager.getProbabilities()){ + sum += prob; + } + if(sum < 1.0*0.99 || sum > 1.0*1.01) throw new IllegalStateException("sum of probabilities is not 1.0, but is "+ sum + ". make sure that the sum of the probability of each searchStrategy is 1.0"); + } + + private void algorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + algoListeners.algorithmEnds(problem, solutions); + } + + public VehicleRoutingAlgorithmListeners getAlgorithmListeners() { + return algoListeners; + } + + private void iterationEnds(int i, VehicleRoutingProblem problem, Collection solutions) { + algoListeners.iterationEnds(i,problem, solutions); + } + + private void iterationStarts(int i, VehicleRoutingProblem problem, Collection solutions) { + algoListeners.iterationStarts(i, problem, solutions); + } + + private void algorithmStarts(VehicleRoutingProblem problem, Collection solutions) { + algoListeners.algorithmStarts(problem, this, solutions); + } + + public void setNuOfIterations(int nOfIterations) { + this.nOfIterations = nOfIterations; + } + +} diff --git a/jsprit-core/src/main/java/basics/VehicleRoutingProblem.java b/jsprit-core/src/main/java/basics/VehicleRoutingProblem.java new file mode 100644 index 00000000..90b3bfe7 --- /dev/null +++ b/jsprit-core/src/main/java/basics/VehicleRoutingProblem.java @@ -0,0 +1,473 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; + +import org.apache.log4j.Logger; + +import util.Coordinate; +import util.CrowFlyCosts; +import util.Locations; +import util.Neighborhood; +import util.NeighborhoodImpl; +import basics.costs.DefaultVehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; + +/** + * Contains and describes the vehicle routing problem. + * + *

A routing problem is defined as jobs, vehicles and costs. + * + *

To construct the problem, use VehicleRoutingProblem.Builder (VehicleRoutingProblem.Builder.newInstance()). + * + *

By default, fleetSize is INFINITE and fleetComposition is HOMOGENEOUS, transport-costs are calculated as euclidean-distance (CrowFlyCosts), + * and activity-costs are set to DefaultVehicleRoutingActivityCosts which represent hard time-windows (missed time-windows are penalyzed with Double.MAX_VALUE). + * + * + * + * @author stefan schroeder + * + */ +public class VehicleRoutingProblem { + + /** + * Builder to build the routing-problem. + * + * @author stefan schroeder + * + */ + public static class Builder { + + /** + * Returns a new instance of this builder. + * + * @return builder + */ + public static Builder newInstance(){ return new Builder(); } + + private VehicleRoutingTransportCosts transportCosts; + + private VehicleRoutingActivityCosts activityCosts = new DefaultVehicleRoutingActivityCosts(); + + private Map jobs; + + private Collection vehicles; + + private Map coordinates; + + private FleetSize fleetSize = FleetSize.INFINITE; + + private FleetComposition fleetComposition = FleetComposition.HOMOGENEOUS; + + private Collection vehicleTypes; + + public Builder() { + jobs = new HashMap(); + vehicles = new ArrayList(); + coordinates = new HashMap(); + vehicleTypes = new ArrayList(); + } + + /** + * Create a location (i.e. coordinate) and returns the key of the location which is Coordinate.toString(). + * + * @param x + * @param y + * @return locationId + * @see Coordinate + */ + public String createLocation(double x, double y){ + Coordinate coord = new Coordinate(x, y); + String id = coord.toString(); + if(!coordinates.containsKey(id)){ + coordinates.put(id, coord); + } + return id; + } + + /** + * Returns the unmodifiable map of locations (mapped by their id). + * + * @return + */ + public Map getLocationMap(){ + return Collections.unmodifiableMap(coordinates); + } + + /** + * Returns the locations collected by this builder. + * + *

Locations are cached when adding a shipment, service, depot, vehicle. + * + * @return locations + * + */ + public Locations getLocations(){ + return new Locations() { + + @Override + public Coordinate getCoord(String id) { + return coordinates.get(id); + } + }; + } + + /** + * Sets routing costs. + * + * @param costs + * @return builder + * @see VehicleRoutingTransportCosts + */ + public Builder setRoutingCost(VehicleRoutingTransportCosts costs){ + this.transportCosts = costs; + return this; + } + + /** + * Sets the type of fleetSize. + * + *

FleetSize is either FleetSize.INFINITE or FleetSize.FINITE + * + * @param fleetSize + * @return + */ + public Builder setFleetSize(FleetSize fleetSize){ + this.fleetSize = fleetSize; +// if(fleetSize.equals(FleetSize.INFINITE)){ +// fleetSizeIsInfinite=true; +// } + return this; + } + + /** + * Sets the fleetComposition. + * + *

FleetComposition is either FleetComposition.HETEROGENEOUS or FleetComposition.HOMOGENEOUS + * + * @param fleetComposition + * @return + */ + public Builder setFleetComposition(FleetComposition fleetComposition){ + this.fleetComposition = fleetComposition; + return this; + } + + /** + * Adds a service to jobList. + * + *

If jobList already contains service, a warning message is printed, and the existing job will be overwritten. + * + * @param service + * @return + */ + public Builder addService(Service service){ + coordinates.put(service.getLocationId(), service.getCoord()); + if(jobs.containsKey(service.getId())){ logger.warn("service " + service + " already in job list. overrides existing job."); } + jobs.put(service.getId(),service); + return this; + } + + /** + * Adds a job which is either a service or a shipment. + * + * @param job + * @return + * @throws IllegalStateException if job is neither a shipment or a service. + */ + public Builder addJob(Job job) { + if(job instanceof Service) { + addService((Service) job); + } +// else if(job instanceof Shipment){ +// addShipment((Shipment)job); +// } + else throw new IllegalStateException("job can only be a shipment or a service, but is instance of " + job.getClass()); + return this; + } + +// private void addShipment(Shipment job) { +// coordinates.put(job.getFromId(),job.getFromCoord()); +// coordinates.put(job.getToId(), job.getToCoord()); +// if(jobs.containsKey(job.getId())){ logger.warn("service " + job + " already in job list. overrides existing job."); } +// jobs.put(job.getId(),job); +// +// } + + /** + * Adds a vehicle. + * + * + * @param vehicle + * @return + */ + public Builder addVehicle(Vehicle vehicle) { +// fleetSizeIsFinite = true; + vehicles.add(vehicle); + if(!vehicleTypes.contains(vehicle.getType())){ + vehicleTypes.add(vehicle.getType()); + } + coordinates.put(vehicle.getLocationId(), vehicle.getCoord()); + return this; + } + + /** + * Adds a vehicleType. + * + * @param type + * @return builder + */ + public Builder addVehicleType(VehicleType type){ + vehicleTypes.add(type); + return this; + } + + + /** + * Sets the activityCostFunction that considers also activities on a vehicle-route. + * + *

Here you can consider missed time-windows for example. By default, this is set to a DefaultVehicleActivityCostFunction. + * + * @param activityCosts + * @return + * @see VehicleRoutingTransportCosts, DefaultVehicleRouteCostFunction + */ + public Builder setActivityCosts(VehicleRoutingActivityCosts activityCosts){ + this.activityCosts = activityCosts; + return this; + } + + public VehicleRoutingProblem build() { + log.info("build problem ..."); + if(transportCosts == null){ + logger.warn("set routing costs crowFlyDistance."); + transportCosts = new CrowFlyCosts(getLocations()); + } + + return new VehicleRoutingProblem(this); + } + + public Builder addLocation(String id, Coordinate coord) { + coordinates.put(id, coord); + return this; + } + + public Builder addAllJobs(Collection jobs) { + for(Job j : jobs){ + addJob(j); + } + return this; + } + + public Builder addAllVehicles(Collection vehicles) { + for(Vehicle v : vehicles){ + addVehicle(v); + } + return this; + } +} + + /** + * Enum that characterizes the fleet-size. + * + * @author sschroeder + * + */ + public static enum FleetSize { + FINITE, INFINITE; + } + + /** + * Enum that characterizes fleet-compostion. + * + * @author sschroeder + * + */ + public static enum FleetComposition { + HETEROGENEOUS, HOMOGENEOUS; + } + + public static Builder newBuilderInstance(){ + return new Builder(); + } + + public static Logger log = Logger.getLogger(VehicleRoutingProblem.class); + + private static Logger logger = Logger.getLogger(VehicleRoutingProblem.class); + + private VehicleRoutingTransportCosts transportCosts; + + private VehicleRoutingActivityCosts activityCosts; + + private Neighborhood neighborhood; + + /** + * @return the neighborhood + */ + public Neighborhood getNeighborhood() { + return neighborhood; + } + + /** + * @param neighborhood the neighborhood to set + */ + public void setNeighborhood(Neighborhood neighborhood) { + this.neighborhood = neighborhood; + } + + private final Map jobs; + + /** + * Collection that contains available vehicles. + */ + private final Collection vehicles; + + /** + * Collection that contains all available types. + */ + private Collection vehicleTypes; + + /** + * An enum that indicates type of fleetSize. By default, it is INFINTE + */ + private FleetSize fleetSize = FleetSize.INFINITE; + + /** + * An enum that indicates fleetSizeComposition. By default, it is HOMOGENOUS. + */ + private FleetComposition fleetComposition; + + + private VehicleRoutingProblem(Builder builder) { + this.jobs = builder.jobs; + this.fleetComposition = builder.fleetComposition; + this.fleetSize = builder.fleetSize; + this.vehicles=builder.vehicles; + this.vehicleTypes = builder.vehicleTypes; + this.transportCosts = builder.transportCosts; + this.activityCosts = builder.activityCosts; + this.neighborhood = new NeighborhoodImpl(this); + log.info("initialise " + this); + } + + @Override + public String toString() { + return "[fleetSize="+fleetSize+"][fleetComposition="+fleetComposition+"][#jobs="+jobs.size()+"][#vehicles="+vehicles.size()+"][#vehicleTypes="+vehicleTypes.size()+"]["+ + "transportCost="+transportCosts+"][activityCosts="+activityCosts+"]"; + } + + /** + * Returns fleet-composition. + * + * @return fleetComposition which is either FleetComposition.HETEROGENEOUS or FleetComposition.HOMOGENEOUS + */ + public FleetComposition getFleetComposition() { + return fleetComposition; + } + + public void setFleetComposition(FleetComposition fleetComposition){ + this.fleetComposition = fleetComposition; + } + + /** + * Returns type of fleetSize, either INFINITE or FINITE. + * + *

By default, it is INFINITE. + * + * @return either FleetSize.INFINITE or FleetSize.FINITE + */ + public FleetSize getFleetSize() { + return fleetSize; + } + + public void setFleetSize(FleetSize fleetSize){ + this.fleetSize = fleetSize; + } + + /** + * Returns the unmodifiable job map. + * + * @return unmodifiable jobMap + */ + public Map getJobs() { + return Collections.unmodifiableMap(jobs); + } + + + /** + * Returns the entire, unmodifiable collection of types. + * + * @return unmodifiable collection of types + * @see VehicleType + */ + public Collection getTypes(){ + return Collections.unmodifiableCollection(vehicleTypes); + } + + + /** + * Returns the entire, unmodifiable collection of vehicles. + * + * @return unmodifiable collection of vehicles + * @see Vehicle + */ + public Collection getVehicles() { + return Collections.unmodifiableCollection(vehicles); + } + + /** + * Returns routing costs. + * + * @return routingCosts + * @see VehicleRoutingTransportCosts + */ + public VehicleRoutingTransportCosts getTransportCosts() { + return transportCosts; + } + + /** + * Sets routing costs. + * + * @param costs + * @see VehicleRoutingTransportCosts + */ + public void setTransportCosts(VehicleRoutingTransportCosts costs) { + this.transportCosts = costs; + logger.info("transport costs set to " + costs.getClass()); + } + + /** + * Returns activityCosts. + */ + public VehicleRoutingActivityCosts getActivityCosts(){ + return activityCosts; + } + + /** + * Sets activityCosts. + */ + public void setActivityCosts(VehicleRoutingActivityCosts activityCosts){ + this.activityCosts = activityCosts; + logger.info("activtiy costs set to " + activityCosts.getClass()); + } + +} diff --git a/jsprit-core/src/main/java/basics/VehicleRoutingProblemSolution.java b/jsprit-core/src/main/java/basics/VehicleRoutingProblemSolution.java new file mode 100644 index 00000000..651b24e3 --- /dev/null +++ b/jsprit-core/src/main/java/basics/VehicleRoutingProblemSolution.java @@ -0,0 +1,87 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import java.util.ArrayList; +import java.util.Collection; + +import basics.route.VehicleRoute; + +/** + * Contains the solution of a vehicle routing problem and its corresponding costs. + * + * @author stefan schröder + * + */ +public class VehicleRoutingProblemSolution { + + public static double NO_COST_YET = -9999.0; + + /** + * Makes a deep copy of the solution to be copied. + * + * @param solution2copy + * @return + */ + public static VehicleRoutingProblemSolution copyOf(VehicleRoutingProblemSolution solution2copy){ + return new VehicleRoutingProblemSolution(solution2copy); + } + + private final Collection routes; + + private double cost; + + private VehicleRoutingProblemSolution(VehicleRoutingProblemSolution solution){ + routes = new ArrayList(); + for(VehicleRoute r : solution.getRoutes()){ + VehicleRoute route = VehicleRoute.copyOf(r); + routes.add(route); + } + this.cost = solution.getCost(); + } + + /** + * Constructs a solution with a number of {@link VehicleRoute}s and their corresponding aggregate cost value. + * + * @param routes + * @param cost + */ + public VehicleRoutingProblemSolution(Collection routes, double cost) { + super(); + this.routes = routes; + this.cost = cost; + } + + + public Collection getRoutes() { + return routes; + } + + + public double getCost() { + return cost; + } + + public void setCost(double cost){ + this.cost = cost; + } + +} diff --git a/jsprit-core/src/main/java/basics/algo/AlgorithmEndsListener.java b/jsprit-core/src/main/java/basics/algo/AlgorithmEndsListener.java new file mode 100644 index 00000000..6521a183 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/AlgorithmEndsListener.java @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public interface AlgorithmEndsListener extends VehicleRoutingAlgorithmListener{ + + void informAlgorithmEnds(VehicleRoutingProblem problem, Collection solutions); + +} diff --git a/jsprit-core/src/main/java/basics/algo/AlgorithmStartsListener.java b/jsprit-core/src/main/java/basics/algo/AlgorithmStartsListener.java new file mode 100644 index 00000000..e3ca000b --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/AlgorithmStartsListener.java @@ -0,0 +1,35 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public interface AlgorithmStartsListener extends VehicleRoutingAlgorithmListener{ + + void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions); + +} diff --git a/jsprit-core/src/main/java/basics/algo/InsertionEndsListener.java b/jsprit-core/src/main/java/basics/algo/InsertionEndsListener.java new file mode 100644 index 00000000..6e845366 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/InsertionEndsListener.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.route.VehicleRoute; + + +public interface InsertionEndsListener extends InsertionListener { + + public void informInsertionEnds(Collection vehicleRoutes); +} diff --git a/jsprit-core/src/main/java/basics/algo/InsertionListener.java b/jsprit-core/src/main/java/basics/algo/InsertionListener.java new file mode 100644 index 00000000..4646ced3 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/InsertionListener.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + + + + + +public interface InsertionListener extends SearchStrategyModuleListener{ + + + +} diff --git a/jsprit-core/src/main/java/basics/algo/InsertionStartsListener.java b/jsprit-core/src/main/java/basics/algo/InsertionStartsListener.java new file mode 100644 index 00000000..a62459cd --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/InsertionStartsListener.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.route.VehicleRoute; + + +public interface InsertionStartsListener extends InsertionListener { + + public void informInsertionStarts(Collection vehicleRoutes, int nOfJobs2Recreate); +} diff --git a/jsprit-core/src/main/java/basics/algo/IterationEndsListener.java b/jsprit-core/src/main/java/basics/algo/IterationEndsListener.java new file mode 100644 index 00000000..05deb377 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/IterationEndsListener.java @@ -0,0 +1,36 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + + +public interface IterationEndsListener extends VehicleRoutingAlgorithmListener{ + + public void informIterationEnds(int i, VehicleRoutingProblem problem, Collection solutions); + + +} diff --git a/jsprit-core/src/main/java/basics/algo/IterationStartsListener.java b/jsprit-core/src/main/java/basics/algo/IterationStartsListener.java new file mode 100644 index 00000000..4af22c03 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/IterationStartsListener.java @@ -0,0 +1,35 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public interface IterationStartsListener extends VehicleRoutingAlgorithmListener{ + + public void informIterationStarts(int i, VehicleRoutingProblem problem, Collection solutions); + + +} diff --git a/jsprit-core/src/main/java/basics/algo/JobInsertedListener.java b/jsprit-core/src/main/java/basics/algo/JobInsertedListener.java new file mode 100644 index 00000000..5cce5484 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/JobInsertedListener.java @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import basics.Job; +import basics.route.VehicleRoute; + + + + + + +public interface JobInsertedListener extends InsertionListener{ + + public void informJobInserted(int nOfJobsStill2Recreate, Job job2insert, VehicleRoute insertedIn); +} diff --git a/jsprit-core/src/main/java/basics/algo/SearchStrategy.java b/jsprit-core/src/main/java/basics/algo/SearchStrategy.java new file mode 100644 index 00000000..f0594dd5 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/SearchStrategy.java @@ -0,0 +1,122 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; + +import org.apache.log4j.Logger; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + +import algorithms.acceptors.SolutionAcceptor; +import algorithms.selectors.SolutionSelector; + + + + + +public class SearchStrategy { + + private static Logger logger = Logger.getLogger(SearchStrategy.class); + + private Collection searchStrategyModules = new ArrayList(); + + private SolutionSelector solutionSelector; + + private SolutionAcceptor solutionAcceptor; + + private String name; + + public SearchStrategy(SolutionSelector solutionSelector, SolutionAcceptor solutionAcceptor) { + super(); + this.solutionSelector = solutionSelector; + this.solutionAcceptor = solutionAcceptor; + logger.info("initialise " + this); + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + + public Collection getSearchStrategyModules() { + return Collections.unmodifiableCollection(searchStrategyModules); + } + + public SolutionSelector getSolutionSelector() { + return solutionSelector; + } + + public SolutionAcceptor getSolutionAcceptor() { + return solutionAcceptor; + } + + @Override + public String toString() { + return "searchStrategy [#modules="+searchStrategyModules.size()+"][selector="+solutionSelector+"][acceptor="+solutionAcceptor+"]"; + } + + /** + * Runs the search-strategy and its according modules, and returns true if a new solution has been accepted. + * + *

This involves three basic steps: 1) Selecting a solution from solutions (input parameter) according to {@link SolutionSelector}, 2) running the modules + * ({@link SearchStrategyModule}) on the selectedSolution and 3) accepting the new solution according to {@link SolutionAcceptor}. + *

Note that after 1) the selected solution is copied, thus the original solution is not modified. + *

Note also that 3) modifies the input parameter solutions by adding, removing, replacing existing solutions. + * + * @param vrp + * @param solutions which will be modified + * @return boolean true if solution has been accepted, false otherwise + * @see SolutionSelector, SearchStrategyModule, SolutionAcceptor + */ + public boolean run(VehicleRoutingProblem vrp, Collection solutions){ + VehicleRoutingProblemSolution solution = solutionSelector.selectSolution(solutions); + if(solution == null) throw new IllegalStateException("solution is null. check solutionSelector to return an appropiate solution."); + VehicleRoutingProblemSolution lastSolution = VehicleRoutingProblemSolution.copyOf(solution); + for(SearchStrategyModule module : searchStrategyModules){ + VehicleRoutingProblemSolution newSolution = module.runAndGetSolution(lastSolution); + lastSolution = newSolution; + } + boolean solutionAccepted = solutionAcceptor.acceptSolution(solutions, lastSolution); + return solutionAccepted; + } + + + public void addModule(SearchStrategyModule module){ + if(module == null) throw new IllegalStateException("module to be added is null."); + searchStrategyModules.add(module); + logger.info("module added [module="+module+"][#modules="+searchStrategyModules.size()+"]"); + } + + public void addModuleListener(SearchStrategyModuleListener moduleListener) { + for(SearchStrategyModule module : searchStrategyModules){ + module.addModuleListener(moduleListener); + } + + } + +} diff --git a/jsprit-core/src/main/java/basics/algo/SearchStrategyListener.java b/jsprit-core/src/main/java/basics/algo/SearchStrategyListener.java new file mode 100644 index 00000000..b3aea8f3 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/SearchStrategyListener.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +public class SearchStrategyListener { + +} diff --git a/jsprit-core/src/main/java/basics/algo/SearchStrategyManager.java b/jsprit-core/src/main/java/basics/algo/SearchStrategyManager.java new file mode 100644 index 00000000..d6c9eceb --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/SearchStrategyManager.java @@ -0,0 +1,102 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Random; + +import util.RandomNumberGeneration; + + +public class SearchStrategyManager { + + private List searchStrategyListeners = new ArrayList(); + + private List strategies = new ArrayList(); + + private List probabilities = new ArrayList(); + + private Random random = RandomNumberGeneration.getRandom(); + + private double sumOfProbabilities = 0; + + public void setRandom(Random random) { + this.random = random; + } + + + public List getStrategies() { + return Collections.unmodifiableList(strategies); + } + + + public List getProbabilities() { + return Collections.unmodifiableList(probabilities); + } + + /** + * adds a new search strategy. the probability must be within [0,1]. + * @param strategy + * @param probability + */ + public void addStrategy(SearchStrategy strategy, double probability){ + if(strategy == null){ + throw new IllegalStateException("strategy is null. make sure adding a valid strategy."); + } + if(probability > 1.0){ + throw new IllegalStateException("probability is higher than one, but it must be within [0,1]."); + } + if(probability < 0.0){ + throw new IllegalStateException("probability is lower than zero, but it must be within [0,1]."); + } + strategies.add(strategy); + probabilities.add(probability); + sumOfProbabilities += probability; + if(sumOfProbabilities > 1.0){ + throw new IllegalStateException("total probability of all strategies is higher than one, but it must be within [0,1]."); + } + } + + public SearchStrategy getRandomStrategy() { + if(random == null) throw new IllegalStateException("randomizer is null. make sure you set random object correctly"); + double randomFig = random.nextDouble(); + double sumWeight = 0.0; + for (int i = 0; i < probabilities.size(); i++) { + sumWeight += probabilities.get(i); + if (randomFig < sumWeight) { + return strategies.get(i); + } + } + throw new IllegalStateException("no seaarch-strategy found"); + } + + public void addSearchStrategyListener(SearchStrategyListener strategyListener){ + searchStrategyListeners.add(strategyListener); + } + + public void addSearchStrategyModuleListener(SearchStrategyModuleListener moduleListener){ + for(SearchStrategy s : strategies){ + s.addModuleListener(moduleListener); + } + } +} diff --git a/jsprit-core/src/main/java/basics/algo/SearchStrategyModule.java b/jsprit-core/src/main/java/basics/algo/SearchStrategyModule.java new file mode 100644 index 00000000..cd02fb44 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/SearchStrategyModule.java @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import basics.VehicleRoutingProblemSolution; + + +public interface SearchStrategyModule { + + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution); + + public String getName(); + + public void addModuleListener(SearchStrategyModuleListener moduleListener); + +} diff --git a/jsprit-core/src/main/java/basics/algo/SearchStrategyModuleListener.java b/jsprit-core/src/main/java/basics/algo/SearchStrategyModuleListener.java new file mode 100644 index 00000000..05d171e3 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/SearchStrategyModuleListener.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +public interface SearchStrategyModuleListener { + +} diff --git a/jsprit-core/src/main/java/basics/algo/StrategySelectedListener.java b/jsprit-core/src/main/java/basics/algo/StrategySelectedListener.java new file mode 100644 index 00000000..3b97ee99 --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/StrategySelectedListener.java @@ -0,0 +1,34 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.Collection; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public interface StrategySelectedListener extends VehicleRoutingAlgorithmListener{ + + void informSelectedStrategy(String strategyName, VehicleRoutingProblem problem, Collection solutions); + +} diff --git a/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmFactory.java b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmFactory.java new file mode 100644 index 00000000..2a3cbfcb --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmFactory.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; + + +public interface VehicleRoutingAlgorithmFactory { + + public VehicleRoutingAlgorithm createAlgorithm(VehicleRoutingProblem vrp); + +} diff --git a/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListener.java b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListener.java new file mode 100644 index 00000000..5ef902ea --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListener.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +public interface VehicleRoutingAlgorithmListener { + +} diff --git a/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListeners.java b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListeners.java new file mode 100644 index 00000000..506a52fe --- /dev/null +++ b/jsprit-core/src/main/java/basics/algo/VehicleRoutingAlgorithmListeners.java @@ -0,0 +1,190 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.Comparator; +import java.util.List; +import java.util.PriorityQueue; +import java.util.TreeSet; + +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public class VehicleRoutingAlgorithmListeners { + + public static class PrioritizedVRAListener { + + Priority priority; + VehicleRoutingAlgorithmListener l; + public PrioritizedVRAListener(Priority priority, VehicleRoutingAlgorithmListener l) { + super(); + this.priority = priority; + this.l = l; + } + public Priority getPriority() { + return priority; + } + public VehicleRoutingAlgorithmListener getListener() { + return l; + } + +// @Override +// public int hashCode() { +// final int prime = 31; +// int result = 1; +// result = prime * result + ((l == null) ? 0 : l.hashCode()); +// result = prime * result +// + ((priority == null) ? 0 : priority.hashCode()); +// return result; +// } +// @Override +// public boolean equals(Object obj) { +// if (this == obj) +// return true; +// if (obj == null) +// return false; +// if (getClass() != obj.getClass()) +// return false; +// PrioritizedVRAListener other = (PrioritizedVRAListener) obj; +// if (l == null) { +// if (other.l != null) +// return false; +// } else if (!l.equals(other.l)) +// return false; +// if (priority == null) { +// if (other.priority != null) +// return false; +// } else if (!priority.equals(other.priority)) +// return false; +// return true; +// } + + } + + public enum Priority { + HIGH, MEDIUM, LOW + } + + + private TreeSet algorithmListeners = new TreeSet(new Comparator() { + + @Override + public int compare(PrioritizedVRAListener o1, PrioritizedVRAListener o2) { + if(o1 == o2) return 0; + if(o1.getPriority() == Priority.HIGH && o2.getPriority() != Priority.HIGH){ + return -1; + } + else if(o2.getPriority() == Priority.HIGH && o1.getPriority() != Priority.HIGH){ + return 1; + } + else if(o1.getPriority() == Priority.MEDIUM && o2.getPriority() != Priority.MEDIUM){ + return -1; + } + else if(o2.getPriority() == Priority.MEDIUM && o1.getPriority() != Priority.MEDIUM){ + return 1; + } + return 1; + } + }); + + + public Collection getAlgorithmListeners() { + List list = new ArrayList(); + for(PrioritizedVRAListener l : algorithmListeners){ + list.add(l.getListener()); + } + return Collections.unmodifiableCollection(list); + } + + public void remove(PrioritizedVRAListener listener){ + boolean removed = algorithmListeners.remove(listener); + if(!removed){ throw new IllegalStateException("cannot remove listener"); } + } + + public void addListener(VehicleRoutingAlgorithmListener listener, Priority priority){ + algorithmListeners.add(new PrioritizedVRAListener(priority, listener)); + } + + public void addListener(VehicleRoutingAlgorithmListener listener){ + addListener(listener, Priority.LOW); + } + + public void algorithmEnds(VehicleRoutingProblem problem, Collection solutions) { + for(PrioritizedVRAListener l : algorithmListeners){ + if(l.getListener() instanceof AlgorithmEndsListener){ + ((AlgorithmEndsListener)l.getListener()).informAlgorithmEnds(problem, solutions); + } + } + + } + + public void iterationEnds(int i, VehicleRoutingProblem problem, Collection solutions) { + for(PrioritizedVRAListener l : algorithmListeners){ + if(l.getListener() instanceof IterationEndsListener){ + ((IterationEndsListener)l.getListener()).informIterationEnds(i,problem, solutions); + } + } + } + + + + public void iterationStarts(int i, VehicleRoutingProblem problem, Collection solutions) { + for(PrioritizedVRAListener l : algorithmListeners){ + if(l.getListener() instanceof IterationStartsListener){ + ((IterationStartsListener)l.getListener()).informIterationStarts(i,problem, solutions); + } + } + } + + + + public void algorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + for(PrioritizedVRAListener l : algorithmListeners){ + if(l.getListener() instanceof AlgorithmStartsListener){ + ((AlgorithmStartsListener)l.getListener()).informAlgorithmStarts(problem, algorithm, solutions); + } + } + } + + public void add(PrioritizedVRAListener l){ + algorithmListeners.add(l); + } + + public void addAll(Collection algorithmListeners) { + for(PrioritizedVRAListener l : algorithmListeners){ + this.algorithmListeners.add(l); + } + } + + public void selectedStrategy(String name, VehicleRoutingProblem problem, Collection solutions) { + for(PrioritizedVRAListener l : algorithmListeners){ + if(l.getListener() instanceof StrategySelectedListener){ + ((StrategySelectedListener)l.getListener()).informSelectedStrategy(name, problem, solutions); + } + } + } +} diff --git a/jsprit-core/src/main/java/basics/costs/BackwardTransportCost.java b/jsprit-core/src/main/java/basics/costs/BackwardTransportCost.java new file mode 100644 index 00000000..fad6f112 --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/BackwardTransportCost.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.Vehicle; + +public interface BackwardTransportCost { + + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle); + +} diff --git a/jsprit-core/src/main/java/basics/costs/BackwardTransportTime.java b/jsprit-core/src/main/java/basics/costs/BackwardTransportTime.java new file mode 100644 index 00000000..9f970bf9 --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/BackwardTransportTime.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.Vehicle; + +public interface BackwardTransportTime { + + public double getBackwardTransportTime(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle); + +} diff --git a/jsprit-core/src/main/java/basics/costs/DefaultVehicleRoutingActivityCosts.java b/jsprit-core/src/main/java/basics/costs/DefaultVehicleRoutingActivityCosts.java new file mode 100644 index 00000000..594a021a --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/DefaultVehicleRoutingActivityCosts.java @@ -0,0 +1,49 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.TourActivity; +import basics.route.Vehicle; + + +/** + * Function that basically does not allow soft time-windows. Actually, it is allowed but it is penalized with Double.MaxValue(). + * + * @author schroeder + * + */ +public class DefaultVehicleRoutingActivityCosts implements VehicleRoutingActivityCosts{ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + if(arrivalTime > tourAct.getTheoreticalLatestOperationStartTime()){ + return Double.MAX_VALUE; + } + return 0; + } + + @Override + public String toString() { + return "[name=hardTimeWindowActCosts]"; + } + +} diff --git a/jsprit-core/src/main/java/basics/costs/ForwardTransportCost.java b/jsprit-core/src/main/java/basics/costs/ForwardTransportCost.java new file mode 100644 index 00000000..495f52f5 --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/ForwardTransportCost.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.Vehicle; + +public interface ForwardTransportCost { + + public double getTransportCost(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle); + +} diff --git a/jsprit-core/src/main/java/basics/costs/ForwardTransportTime.java b/jsprit-core/src/main/java/basics/costs/ForwardTransportTime.java new file mode 100644 index 00000000..780cc83d --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/ForwardTransportTime.java @@ -0,0 +1,31 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.Vehicle; + +public interface ForwardTransportTime { + + public double getTransportTime(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle); + +} diff --git a/jsprit-core/src/main/java/basics/costs/TransportCost.java b/jsprit-core/src/main/java/basics/costs/TransportCost.java new file mode 100644 index 00000000..57a03389 --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/TransportCost.java @@ -0,0 +1,26 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + + +public interface TransportCost extends ForwardTransportCost, BackwardTransportCost{ + +} diff --git a/jsprit-core/src/main/java/basics/costs/TransportTime.java b/jsprit-core/src/main/java/basics/costs/TransportTime.java new file mode 100644 index 00000000..fc01b650 --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/TransportTime.java @@ -0,0 +1,26 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + + +public interface TransportTime extends ForwardTransportTime, BackwardTransportTime{ + +} diff --git a/jsprit-core/src/main/java/basics/costs/VehicleRoutingActivityCosts.java b/jsprit-core/src/main/java/basics/costs/VehicleRoutingActivityCosts.java new file mode 100644 index 00000000..f0c2a2cc --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/VehicleRoutingActivityCosts.java @@ -0,0 +1,71 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + +import basics.route.Driver; +import basics.route.TourActivity; +import basics.route.Vehicle; + +/** + * Interface for overall routing and operation costs. + * + *

This calculates activity and leg-based costs. If you want to consider for example costs incurred by missed time-windows, you can do it here. + * + * @author schroeder + * + */ +public interface VehicleRoutingActivityCosts { + + public static class Time { + + public static double TOUREND = -2.0; + + public static double TOURSTART = -1.0; + + public static double UNDEFINED = -3.0; + } + + public static interface Parameter { + + public double getPenaltyForMissedTimeWindow(); + + } + + /** + * Calculates and returns the activity cost at tourAct. + * + *

Here waiting-times, service-times and missed time-windows can be considered. + * + * @param tourAct + * @param arrivalTime is actually the arrival time at this tourActivity, which must not nessecarrily be the operation start time. If the theoretical earliest + * operation start time at this activity is later than actualStartTime, the driver must wait at this activity. + * @param driver TODO + * @param vehicle TODO + * @param earliestStartTime, this is the practical earliest operation start time which considers also previous activities. + * @param latestStartTime, this is the practical latest operation start time which consider also future activities in the tour. + * if earliestStartTime > latestStartTime activity operations cannot be conducted within the given time-window. + * @return + */ + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle); + +// public Parameter getParameter(TourActivity tourAct, Vehicle vehicle, Driver driver); + +} diff --git a/jsprit-core/src/main/java/basics/costs/VehicleRoutingTransportCosts.java b/jsprit-core/src/main/java/basics/costs/VehicleRoutingTransportCosts.java new file mode 100644 index 00000000..16e9409a --- /dev/null +++ b/jsprit-core/src/main/java/basics/costs/VehicleRoutingTransportCosts.java @@ -0,0 +1,28 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.costs; + + +/** + * Interface for transportCost and transportTime. + * + *

Transport here is what happens between two activities within the transport system, i.e. in the physical transport network. And + * must give the answer of how long does it take from A to B, and how much does this cost. + * + * @author schroeder + * + */ + +public interface VehicleRoutingTransportCosts extends TransportTime, TransportCost { + +} diff --git a/jsprit-core/src/main/java/basics/io/AlgorithmConfig.java b/jsprit-core/src/main/java/basics/io/AlgorithmConfig.java new file mode 100644 index 00000000..fa791305 --- /dev/null +++ b/jsprit-core/src/main/java/basics/io/AlgorithmConfig.java @@ -0,0 +1,37 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import org.apache.commons.configuration.XMLConfiguration; + +public class AlgorithmConfig { + + private XMLConfiguration xmlConfig; + + public AlgorithmConfig(){ + xmlConfig = new XMLConfiguration(); + + } + + public XMLConfiguration getXMLConfiguration(){ + return xmlConfig; + } +} diff --git a/jsprit-core/src/main/java/basics/io/AlgorithmConfigXmlReader.java b/jsprit-core/src/main/java/basics/io/AlgorithmConfigXmlReader.java new file mode 100644 index 00000000..c2479641 --- /dev/null +++ b/jsprit-core/src/main/java/basics/io/AlgorithmConfigXmlReader.java @@ -0,0 +1,87 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import java.io.IOException; +import java.net.URL; + +import org.apache.commons.configuration.ConfigurationException; +import org.apache.log4j.Logger; +import org.xml.sax.EntityResolver; +import org.xml.sax.InputSource; +import org.xml.sax.SAXException; + +public class AlgorithmConfigXmlReader { + + private static Logger log = Logger.getLogger(AlgorithmConfigXmlReader.class); + + private AlgorithmConfig algorithmConfig; + + private boolean schemaValidation = true; + + /** + * @param schemaValidation the schemaValidation to set + */ + public void setSchemaValidation(boolean schemaValidation) { + this.schemaValidation = schemaValidation; + } + + public AlgorithmConfigXmlReader(AlgorithmConfig algorithmConfig){ + this.algorithmConfig = algorithmConfig; + } + + public void read(String filename){ + log.info("read algorithm-config from file " + filename); + algorithmConfig.getXMLConfiguration().setFileName(filename); + algorithmConfig.getXMLConfiguration().setAttributeSplittingDisabled(true); + algorithmConfig.getXMLConfiguration().setDelimiterParsingDisabled(true); + + if(schemaValidation){ + final URL resource = this.getClass().getClassLoader().getResource("algorithm_schema.xsd"); + if(resource != null) { + EntityResolver resolver = new EntityResolver() { + + @Override + public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException { + { + InputSource is = new InputSource(resource.getFile()); + return is; + } + } + }; + algorithmConfig.getXMLConfiguration().setEntityResolver(resolver); + algorithmConfig.getXMLConfiguration().setSchemaValidation(true); + log.info("validating " + filename + " with xsd-schema"); + } + else{ + log.warn("cannot find schema-xsd file (algorithm_xml_schema.xsd). try to read xml without xml-file-validation."); + } + } + try { + algorithmConfig.getXMLConfiguration().load(); + } catch (ConfigurationException e) { + log.error(e); + e.printStackTrace(); + System.exit(1); + } + } + +} diff --git a/jsprit-core/src/main/java/basics/io/Schema.java b/jsprit-core/src/main/java/basics/io/Schema.java new file mode 100644 index 00000000..0075196c --- /dev/null +++ b/jsprit-core/src/main/java/basics/io/Schema.java @@ -0,0 +1,67 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +final class Schema { + + public static final String PROBLEM = "problem"; + public static final String VEHICLE = "vehicle"; + public static final String TYPES = "vehicleTypes"; + public static final String VEHICLES = "vehicles"; + public static final String SHIPMENTS = "shipments"; + public static final String SHIPMENT = "shipment"; + public static final String SERVICETIME = "serviceTime"; + public static final String PICKUP = "pickup"; + public static final String TYPE = "type"; + + + public void dot(){ + + } + + public static class PathBuilder { + + StringBuilder stringBuilder = new StringBuilder(); + boolean justCreated = true; + + + public PathBuilder dot(String string){ + stringBuilder.append(".").append(string); + return this; + } + + public PathBuilder append(String string){ + stringBuilder.append(string); + return this; + } + + public String build(){ return stringBuilder.toString(); } + + } + + public static PathBuilder builder(){ + return new PathBuilder(); + } + + private Schema(){ + + } +} diff --git a/jsprit-core/src/main/java/basics/io/VrpXMLReader.java b/jsprit-core/src/main/java/basics/io/VrpXMLReader.java new file mode 100644 index 00000000..0b0262a8 --- /dev/null +++ b/jsprit-core/src/main/java/basics/io/VrpXMLReader.java @@ -0,0 +1,320 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import java.io.IOException; +import java.net.URL; +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.apache.commons.configuration.ConfigurationException; +import org.apache.commons.configuration.HierarchicalConfiguration; +import org.apache.commons.configuration.XMLConfiguration; +import org.apache.log4j.Logger; +import org.xml.sax.EntityResolver; +import org.xml.sax.InputSource; +import org.xml.sax.SAXException; + +import util.Coordinate; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; +import basics.VehicleRoutingProblemSolution; +import basics.route.Driver; +import basics.route.DriverImpl; +import basics.route.End; +import basics.route.ServiceActivity; +import basics.route.Start; +import basics.route.TimeWindow; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleBuilder; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + +public class VrpXMLReader{ + + private static Logger logger = Logger.getLogger(VrpXMLReader.class); + + private VehicleRoutingProblem.Builder vrpBuilder; + + private Map vehicleMap; + + private Map serviceMap; + + private boolean schemaValidation = true; + + private Collection solutions; + + /** + * @param schemaValidation the schemaValidation to set + */ + public void setSchemaValidation(boolean schemaValidation) { + this.schemaValidation = schemaValidation; + } + + public VrpXMLReader(VehicleRoutingProblem.Builder vrpBuilder, Collection solutions){ + this.vrpBuilder = vrpBuilder; + this.vehicleMap = new HashMap(); + this.serviceMap = new HashMap(); + this.solutions = solutions; + } + + public VrpXMLReader(VehicleRoutingProblem.Builder vrpBuilder){ + this.vrpBuilder = vrpBuilder; + this.vehicleMap = new HashMap(); + this.serviceMap = new HashMap(); + this.solutions = null; + } + + public void read(String filename) { + logger.info("read vrp from file " + filename); + XMLConfiguration xmlConfig = new XMLConfiguration(); + xmlConfig.setFileName(filename); + xmlConfig.setAttributeSplittingDisabled(true); + xmlConfig.setDelimiterParsingDisabled(true); + + if(schemaValidation){ + final URL resource = this.getClass().getClassLoader().getResource("vrp_xml_schema.xsd"); + if(resource != null) { + EntityResolver resolver = new EntityResolver() { + + @Override + public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException { + { + InputSource is = new InputSource(resource.getFile()); + return is; + } + } + }; + xmlConfig.setEntityResolver(resolver); + xmlConfig.setSchemaValidation(true); + logger.info("validating " + filename + " with xsd-schema"); + } + else{ + logger.warn("cannot find schema-xsd file (vrp_xml_schema.xsd). try to read xml without xml-file-validation."); + } + } + try { + xmlConfig.load(); + } catch (ConfigurationException e) { + logger.error(e); + e.printStackTrace(); + System.exit(1); + } + readProblemType(xmlConfig); + readVehiclesAndTheirTypes(xmlConfig); + readServices(xmlConfig); + readSolutions(xmlConfig); + } + + private void readSolutions(XMLConfiguration vrpProblem) { + if(solutions == null) return; + List solutionConfigs = vrpProblem.configurationsAt("solutions.solution"); + for(HierarchicalConfiguration solutionConfig : solutionConfigs){ + String totalCost = solutionConfig.getString("cost"); + double cost = -1; + if(totalCost != null) cost = Double.parseDouble(totalCost); + List routeConfigs = solutionConfig.configurationsAt("routes.route"); + List routes = new ArrayList(); + for(HierarchicalConfiguration routeConfig : routeConfigs){ + String driverId = routeConfig.getString("driverId"); + //! here, driverId is set to noDriver, no matter whats in driverId. + Driver driver = DriverImpl.noDriver(); + String vehicleId = routeConfig.getString("vehicleId"); + Vehicle vehicle = getVehicle(vehicleId); + if(vehicle == null) throw new IllegalStateException("vehicle is missing."); + String start = routeConfig.getString("start"); + if(start == null) throw new IllegalStateException("route start-time is missing."); + String end = routeConfig.getString("end"); + if(end == null) throw new IllegalStateException("route end-time is missing."); + Start startAct = Start.newInstance(vehicle.getLocationId(), vehicle.getEarliestDeparture(), vehicle.getLatestArrival()); + startAct.setEndTime(Double.parseDouble(start)); + End endAct = End.newInstance(vehicle.getLocationId(), vehicle.getEarliestDeparture(), vehicle.getLatestArrival()); + endAct.setArrTime(Double.parseDouble(end)); + VehicleRoute.Builder routeBuilder = VehicleRoute.Builder.newInstance(startAct, endAct); + routeBuilder.setDriver(driver); + routeBuilder.setVehicle(vehicle); + List actConfigs = routeConfig.configurationsAt("act"); + for(HierarchicalConfiguration actConfig : actConfigs){ + String type = actConfig.getString("[@type]"); + if(type == null) throw new IllegalStateException("act[@type] is missing."); + String serviceId = actConfig.getString("serviceId"); + if(serviceId == null) throw new IllegalStateException("act.serviceId is missing."); + Service service = getService(serviceId); + String arrTime = actConfig.getString("arrTime"); + if(arrTime == null) throw new IllegalStateException("act.arrTime is missing."); + String endTime = actConfig.getString("endTime"); + if(endTime == null) throw new IllegalStateException("act.endTime is missing."); + ServiceActivity serviceActivity = ServiceActivity.newInstance(service); + serviceActivity.setArrTime(Double.parseDouble(arrTime)); + serviceActivity.setEndTime(Double.parseDouble(endTime)); + routeBuilder.addActivity(serviceActivity); + } + routes.add(routeBuilder.build()); + } + VehicleRoutingProblemSolution solution = new VehicleRoutingProblemSolution(routes, cost); + solutions.add(solution); + } + } + + private Service getService(String serviceId) { + return serviceMap.get(serviceId); + } + + private Vehicle getVehicle(String vehicleId) { + return vehicleMap.get(vehicleId); + } + + private void readProblemType(XMLConfiguration vrpProblem) { + String fleetSize = vrpProblem.getString("problemType.fleetSize"); + if(fleetSize == null) vrpBuilder.setFleetSize(FleetSize.INFINITE); + else if(fleetSize.toUpperCase().equals(FleetSize.INFINITE.toString())) vrpBuilder.setFleetSize(FleetSize.INFINITE); + else vrpBuilder.setFleetSize(FleetSize.FINITE); + + String fleetComposition = vrpProblem.getString("problemType.fleetComposition"); + if(fleetComposition == null) vrpBuilder.setFleetComposition(FleetComposition.HOMOGENEOUS); + else if(fleetComposition.toUpperCase().equals(FleetComposition.HETEROGENEOUS.toString())){ + vrpBuilder.setFleetComposition(FleetComposition.HETEROGENEOUS); + } + else vrpBuilder.setFleetComposition(FleetComposition.HOMOGENEOUS); + + } + + private void readServices(XMLConfiguration vrpProblem) { + List serviceConfigs = vrpProblem.configurationsAt("services.service"); + for(HierarchicalConfiguration serviceConfig : serviceConfigs){ + String id = serviceConfig.getString("[@id]"); + if(id == null) throw new IllegalStateException("service[@id] is missing."); + String name = serviceConfig.getString("[@type]"); + if(name == null) name = "service"; + String capacityDemand = serviceConfig.getString("capacity-demand"); + int cap = 0; + if(capacityDemand != null) cap = Integer.parseInt(capacityDemand); + Service.Builder builder = Service.Builder.newInstance(id, cap); + builder.setName(name); + String serviceLocationId = serviceConfig.getString("locationId"); + builder.setLocationId(serviceLocationId); + Coordinate serviceCoord = null; + if(serviceConfig.getString("coord[@x]") != null && serviceConfig.getString("coord[@y]") != null){ + double x = Double.parseDouble(serviceConfig.getString("coord[@x]")); + double y = Double.parseDouble(serviceConfig.getString("coord[@y]")); + serviceCoord = Coordinate.newInstance(x,y); + } + builder.setCoord(serviceCoord); + if(serviceCoord != null){ + if(serviceLocationId != null){ + vrpBuilder.addLocation(serviceLocationId,serviceCoord); + } + else{ + vrpBuilder.addLocation(serviceCoord.toString(),serviceCoord); + builder.setLocationId(serviceCoord.toString()); + } + } + + + if(serviceConfig.containsKey("duration")){ + builder.setServiceTime(serviceConfig.getDouble("duration")); + } + List deliveryTWConfigs = serviceConfig.configurationsAt("timeWindows.timeWindow"); + if(!deliveryTWConfigs.isEmpty()){ + for(HierarchicalConfiguration twConfig : deliveryTWConfigs){ + builder.setTimeWindow(TimeWindow.newInstance(twConfig.getDouble("start"), twConfig.getDouble("end"))); + } + } + Service service = builder.build(); + serviceMap.put(service.getId(),service); + vrpBuilder.addJob(service); + + } + } + + private void readVehiclesAndTheirTypes(XMLConfiguration vrpProblem) { + + //read vehicle-types + Map types = new HashMap(); + List typeConfigs = vrpProblem.configurationsAt("vehicleTypes.type"); + for(HierarchicalConfiguration typeConfig : typeConfigs){ + String typeId = typeConfig.getString("id"); + Integer capacity = typeConfig.getInt("capacity"); + Double fix = typeConfig.getDouble("costs.fixed"); + Double timeC = typeConfig.getDouble("costs.time"); + Double distC = typeConfig.getDouble("costs.distance"); +// Double start = typeConfig.getDouble("timeSchedule.start"); +// Double end = typeConfig.getDouble("timeSchedule.end"); + if(typeId == null) throw new IllegalStateException("typeId is missing."); + if(capacity == null) throw new IllegalStateException("capacity is missing."); + VehicleType.Builder typeBuilder = VehicleType.Builder.newInstance(typeId, capacity); + if(fix != null) typeBuilder.setFixedCost(fix); + if(timeC != null) typeBuilder.setCostPerTime(timeC); + if(distC != null) typeBuilder.setCostPerDistance(distC); +// if(start != null && end != null) typeBuilder.setTimeSchedule(new TimeSchedule(start, end)); + VehicleType type = typeBuilder.build(); + types.put(type.typeId, type); + vrpBuilder.addVehicleType(type); + } + + //read vehicles + List vehicleConfigs = vrpProblem.configurationsAt("vehicles.vehicle"); + boolean doNotWarnAgain = false; + for(HierarchicalConfiguration vehicleConfig : vehicleConfigs){ + String vehicleId = vehicleConfig.getString("id"); + if(vehicleId == null) throw new IllegalStateException("vehicleId is missing."); + VehicleBuilder builder = VehicleImpl.VehicleBuilder.newInstance(vehicleId); + String typeId = vehicleConfig.getString("typeId"); + if(typeId == null) throw new IllegalStateException("typeId is missing."); + VehicleType type = types.get(typeId); + if(type == null) throw new IllegalStateException("vehicleType with typeId " + typeId + " is missing."); + builder.setType(type); + String locationId = vehicleConfig.getString("location.id"); + if(locationId == null) throw new IllegalStateException("location.id is missing."); + builder.setLocationId(locationId); + String coordX = vehicleConfig.getString("location.coord[@x]"); + String coordY = vehicleConfig.getString("location.coord[@y]"); + if(coordX == null || coordY == null) { + if(!doNotWarnAgain) { + logger.warn("location.coord is missing. do not warn you again."); + doNotWarnAgain = true; + } + } + else{ + Coordinate coordinate = Coordinate.newInstance(Double.parseDouble(coordX), Double.parseDouble(coordY)); + builder.setLocationCoord(coordinate); + } + String start = vehicleConfig.getString("timeSchedule.start"); + String end = vehicleConfig.getString("timeSchedule.end"); + if(start != null) builder.setEarliestStart(Double.parseDouble(start)); + if(end != null) builder.setLatestArrival(Double.parseDouble(end)); + VehicleImpl vehicle = builder.build(); +// vehicleMap.put(vehicle.getId(), vehicle); + vrpBuilder.addVehicle(vehicle); + vehicleMap.put(vehicleId, vehicle); + } + + } + + + +} diff --git a/jsprit-core/src/main/java/basics/io/VrpXMLWriter.java b/jsprit-core/src/main/java/basics/io/VrpXMLWriter.java new file mode 100644 index 00000000..53b777d6 --- /dev/null +++ b/jsprit-core/src/main/java/basics/io/VrpXMLWriter.java @@ -0,0 +1,295 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import java.io.FileWriter; +import java.io.IOException; +import java.io.Writer; +import java.util.Collection; + +import org.apache.commons.configuration.ConfigurationException; +import org.apache.commons.configuration.XMLConfiguration; +import org.apache.log4j.Logger; +import org.apache.xml.serialize.OutputFormat; +import org.apache.xml.serialize.XMLSerializer; +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.route.ServiceActivity; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + +public class VrpXMLWriter { + + static class XMLConf extends XMLConfiguration { + + + public Document createDoc() throws ConfigurationException{ + Document doc = createDocument(); + return doc; + } + } + + private Logger log = Logger.getLogger(VrpXMLWriter.class); + + private VehicleRoutingProblem vrp; + + private Collection solutions; + + public VrpXMLWriter(VehicleRoutingProblem vrp, Collection solutions) { + this.vrp = vrp; + this.solutions = solutions; + } + + public VrpXMLWriter(VehicleRoutingProblem vrp) { + this.vrp = vrp; + this.solutions = null; + } + + private static Logger logger = Logger.getLogger(VrpXMLWriter.class); + + public void write(String filename){ + log.info("write vrp to " + filename); + XMLConf xmlConfig = new XMLConf(); + xmlConfig.setFileName(filename); + xmlConfig.setRootElementName("problem"); + xmlConfig.setAttributeSplittingDisabled(true); + xmlConfig.setDelimiterParsingDisabled(true); + + + writeProblemType(xmlConfig); + writeVehiclesAndTheirTypes(xmlConfig); + writerServices(xmlConfig); +// writeShipments(xmlConfig); + writeSolutions(xmlConfig); + + OutputFormat format = new OutputFormat(); + format.setIndenting(true); + format.setIndent(5); + + try { + Document document = xmlConfig.createDoc(); + + Element element = document.getDocumentElement(); + element.setAttribute("xmlns", "http://www.w3schools.com"); + element.setAttribute("xmlns:xsi","http://www.w3.org/2001/XMLSchema-instance"); + element.setAttribute("xsi:schemaLocation","http://www.w3schools.com vrp_xml_schema.xsd"); + + } catch (ConfigurationException e) { + logger.error(e); + e.printStackTrace(); + System.exit(1); + } + + try { + Writer out = new FileWriter(filename); + XMLSerializer serializer = new XMLSerializer(out, format); + serializer.serialize(xmlConfig.getDocument()); + } catch (IOException e) { + logger.error(e); + e.printStackTrace(); + System.exit(1); + } + + + } + + private void writeSolutions(XMLConf xmlConfig) { + if(solutions == null) return; + String solutionPath = "solutions.solution"; + int counter = 0; + for(VehicleRoutingProblemSolution solution : solutions){ + xmlConfig.setProperty(solutionPath + "(" + counter + ").cost", solution.getCost()); + int routeCounter = 0; + for(VehicleRoute route : solution.getRoutes()){ + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").cost", route.getCost()); + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").driverId", route.getDriver().getId()); + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").vehicleId", route.getVehicle().getId()); + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").start", route.getStart().getEndTime()); + int actCounter = 0; + for(TourActivity act : route.getTourActivities().getActivities()){ + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").act("+actCounter+")[@type]", act.getName()); + if(act instanceof ServiceActivity){ + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").act("+actCounter+").serviceId", ((ServiceActivity) act).getJob().getId()); + } + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").act("+actCounter+").arrTime", act.getArrTime()); + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").act("+actCounter+").endTime", act.getEndTime()); + actCounter++; + } + xmlConfig.setProperty(solutionPath + "(" + counter + ").routes.route(" + routeCounter + ").end", route.getEnd().getArrTime()); + routeCounter++; + } + counter++; + } + } + + private void writerServices(XMLConf xmlConfig) { + String shipmentPathString = "services.service"; + int counter = 0; + for(Job j : vrp.getJobs().values()){ + Service service = (Service) j; + xmlConfig.setProperty(shipmentPathString + "("+counter+")[@id]", service.getId()); + xmlConfig.setProperty(shipmentPathString + "("+counter+")[@type]", service.getType()); + if(service.getLocationId() != null) xmlConfig.setProperty(shipmentPathString + "("+counter+").locationId", service.getLocationId()); + if(service.getCoord() != null) { + xmlConfig.setProperty(shipmentPathString + "("+counter+").coord[@x]", service.getCoord().getX()); + xmlConfig.setProperty(shipmentPathString + "("+counter+").coord[@y]", service.getCoord().getY()); + } + xmlConfig.setProperty(shipmentPathString + "("+counter+").capacity-demand", service.getCapacityDemand()); + xmlConfig.setProperty(shipmentPathString + "("+counter+").duration", service.getServiceDuration()); + xmlConfig.setProperty(shipmentPathString + "("+counter+").timeWindows.timeWindow(0).start", service.getTimeWindow().getStart()); + xmlConfig.setProperty(shipmentPathString + "("+counter+").timeWindows.timeWindow(0).end", service.getTimeWindow().getEnd()); + + counter++; + } + + + } + +// private void writeShipments(XMLConf xmlConfig) { +// String shipmentPathString = "shipments.shipment"; +// int counter = 0; +// for(Job j : vrp.getJobs().values()){ +// Shipment shipment = (Shipment) j; +// xmlConfig.setProperty(shipmentPathString + "("+counter+")[@id]", shipment.getId()); +// if(shipment.getFromId() != null) xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.locationId", shipment.getFromId()); +// if(shipment.getFromCoord() != null) { +// xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.coord[@x]", shipment.getFromCoord().getX()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.coord[@y]", shipment.getFromCoord().getY()); +// } +// if(shipment.getToId() != null) xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.locationId", shipment.getToId()); +// if(shipment.getFromCoord() != null) { +// xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.coord[@x]", shipment.getToCoord().getX()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.coord[@y]", shipment.getToCoord().getY()); +// } +// xmlConfig.setProperty(shipmentPathString + "("+counter+").size", shipment.getSize()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.serviceTime", shipment.getPickupServiceTime()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.timeWindows.timeWindow(0).start", shipment.getPickupTW().getStart()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").pickup.timeWindows.timeWindow(0).end", shipment.getPickupTW().getEnd()); +// +// xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.serviceTime", shipment.getDeliveryServiceTime()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.timeWindows.timeWindow(0).start", shipment.getDeliveryTW().getStart()); +// xmlConfig.setProperty(shipmentPathString + "("+counter+").delivery.timeWindows.timeWindow(0).end", shipment.getDeliveryTW().getEnd()); +// +// counter++; +// } +// +// } + + private void writeProblemType(XMLConfiguration xmlConfig){ + xmlConfig.setProperty("problemType.fleetSize", vrp.getFleetSize()); + xmlConfig.setProperty("problemType.fleetComposition", vrp.getFleetComposition()); + } + + private void writeVehiclesAndTheirTypes(XMLConfiguration xmlConfig) { + +// //depots +// Map depot2id = new HashMap(); +// int depotCounter = 0; +// for(Depot depot : vrp.getDepots()){ +// int depotId = depotCounter+1; +// depot2id.put(depot, depotId); +// xmlConfig.setProperty("depots.depot" + "("+depotCounter+")[@id]", (depotId)); +// xmlConfig.setProperty("depots.depot" + "("+depotCounter+").locationId", depot.getId()); +// xmlConfig.setProperty("depots.depot" + "("+depotCounter+").coord[@x]", depot.getCoord().getX()); +// xmlConfig.setProperty("depots.depot" + "("+depotCounter+").coord[@y]", depot.getCoord().getY()); +// depotCounter++; +// } + + //vehicles + String vehiclePathString = new StringBuilder().append(Schema.VEHICLES).append("."). + append(Schema.VEHICLE).toString(); + int counter = 0; + for(Vehicle vehicle : vrp.getVehicles()){ + xmlConfig.setProperty(vehiclePathString + "("+counter+").id", vehicle.getId()); + xmlConfig.setProperty(vehiclePathString + "("+counter+").typeId", vehicle.getType().typeId); + xmlConfig.setProperty(vehiclePathString + "("+counter+").location.id", vehicle.getLocationId()); + if(vehicle.getCoord() != null){ + xmlConfig.setProperty(vehiclePathString + "("+counter+").location.coord[@x]", vehicle.getCoord().getX()); + xmlConfig.setProperty(vehiclePathString + "("+counter+").location.coord[@y]", vehicle.getCoord().getY()); + } + xmlConfig.setProperty(vehiclePathString + "("+counter+").timeSchedule.start", vehicle.getEarliestDeparture()); + xmlConfig.setProperty(vehiclePathString + "("+counter+").timeSchedule.end", vehicle.getLatestArrival()); +// if(vehicle.getLocationId() != null) xmlConfig.setProperty(vehiclePathString + "("+counter+").locationId", vehicle.getLocationId()); +// if(vehicle.getCoord() != null) { +// xmlConfig.setProperty(vehiclePathString + "("+counter+").coord[@x]", vehicle.getCoord().getX()); +// xmlConfig.setProperty(vehiclePathString + "("+counter+").coord[@y]", vehicle.getCoord().getY()); +// } +// xmlConfig.setProperty(vehiclePathString + "("+counter+").earliestStart", vehicle.getEarliestDeparture()); +// xmlConfig.setProperty(vehiclePathString + "("+counter+").latestEnd", vehicle.getLatestArrival()); + counter++; + } + + //types + String typePathString = Schema.builder().append(Schema.TYPES).dot(Schema.TYPE).build(); + int typeCounter = 0; + for(VehicleType type : vrp.getTypes()){ + xmlConfig.setProperty(typePathString + "("+typeCounter+").id", type.typeId); + xmlConfig.setProperty(typePathString + "("+typeCounter+").capacity", type.capacity); +// xmlConfig.setProperty(typePathString + "("+typeCounter+").timeSchedule.start", type.getTimeSchedule().getEarliestStart()); +// xmlConfig.setProperty(typePathString + "("+typeCounter+").timeSchedule.end", type.getTimeSchedule().getLatestEnd()); + xmlConfig.setProperty(typePathString + "("+typeCounter+").costs.fixed", type.vehicleCostParams.fix); + xmlConfig.setProperty(typePathString + "("+typeCounter+").costs.distance", type.vehicleCostParams.perDistanceUnit); + xmlConfig.setProperty(typePathString + "("+typeCounter+").costs.time", type.vehicleCostParams.perTimeUnit); + typeCounter++; + } + + +// //type2depot assignments +// int assignmentCounter = 0; +// boolean first = true; +// for(Depot depot : vrp.getDepotToVehicleTypeAssignments().keySet()){ +// if(first){ +// xmlConfig.setProperty("assignments[@type]", "vehicleType2depot"); +// } +// for(VehicleType type : vrp.getDepotToVehicleTypeAssignments().get(depot)){ +// xmlConfig.setProperty("assignments.assignment" + "("+assignmentCounter+").depotId", depot2id.get(depot)); +// xmlConfig.setProperty("assignments.assignment" + "("+assignmentCounter+").vehicleTypeId", type.getTypeId()); +// assignmentCounter++; +// } +// } +// +// //vehicle2depot assignments +// int vehicleAssignmentCounter = 0; +// boolean first_ = true; +// for(Depot depot : vrp.getDepotToVehicleAssignments().keySet()){ +// if(first_){ +// xmlConfig.setProperty("assignments[@type]", "vehicle2depot"); +// } +// for(Vehicle vehicle : vrp.getDepotToVehicleAssignments().get(depot)){ +// xmlConfig.setProperty("assignments.assignment" + "("+vehicleAssignmentCounter+").depotId", depot2id.get(depot)); +// xmlConfig.setProperty("assignments.assignment" + "("+vehicleAssignmentCounter+").vehicleId", vehicle.getId()); +// vehicleAssignmentCounter++; +// } +// } +// + + + + } + +} diff --git a/jsprit-core/src/main/java/basics/route/DefaultVehicleRouteCostCalculator.java b/jsprit-core/src/main/java/basics/route/DefaultVehicleRouteCostCalculator.java new file mode 100644 index 00000000..5d605c73 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/DefaultVehicleRouteCostCalculator.java @@ -0,0 +1,133 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import basics.route.VehicleImpl.VehicleType; + + +public class DefaultVehicleRouteCostCalculator implements VehicleRouteCostCalculator { + + private double tpCosts = 0.0; + private double actCosts = 0.0; + private double vehicleCosts = 0.0; + private double driverCosts = 0.0; + private double other = 0.0; + + public DefaultVehicleRouteCostCalculator(){} + + private DefaultVehicleRouteCostCalculator(DefaultVehicleRouteCostCalculator costCalc){ + this.tpCosts=costCalc.getTpCosts(); + this.actCosts = costCalc.getActCosts(); + this.driverCosts = costCalc.getDriverCosts(); + this.other = costCalc.getOther(); + this.vehicleCosts = costCalc.getVehicleCosts(); + } + + public void addTransportCost(double tpCost) { + this.tpCosts+=tpCost; + } + + public void addActivityCost(double actCost){ + this.actCosts+=actCost; + } + + public void price(Vehicle vehicle){ + if(vehicle != null){ + VehicleType type = vehicle.getType(); + if(type != null){ + this.vehicleCosts = type.getVehicleCostParams().fix; + } + } + } + + public void price(Driver driver){ + + } + + @Override + public void finish() { + // TODO Auto-generated method stub + + } + + @Override + public void reset() { + tpCosts = 0.0; + actCosts = 0.0; + vehicleCosts = 0.0; + driverCosts = 0.0; + other = 0.0; + } + + @Override + public void addOtherCost(double cost) { + this.other = cost; + + } + + @Override + public double getCosts() { + return tpCosts + actCosts + vehicleCosts + driverCosts + other; + } + + /** + * @return the tpCosts + */ + public double getTpCosts() { + return tpCosts; + } + + /** + * @return the actCosts + */ + public double getActCosts() { + return actCosts; + } + + /** + * @return the vehicleCosts + */ + public double getVehicleCosts() { + return vehicleCosts; + } + + /** + * @return the driverCosts + */ + public double getDriverCosts() { + return driverCosts; + } + + /** + * @return the other + */ + public double getOther() { + return other; + } + + @Override + public VehicleRouteCostCalculator duplicate() { + return new DefaultVehicleRouteCostCalculator(this); + } + + + +} diff --git a/jsprit-core/src/main/java/basics/route/Driver.java b/jsprit-core/src/main/java/basics/route/Driver.java new file mode 100644 index 00000000..001b4db6 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/Driver.java @@ -0,0 +1,27 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +public interface Driver { + + public String getId(); + +} diff --git a/jsprit-core/src/main/java/basics/route/DriverImpl.java b/jsprit-core/src/main/java/basics/route/DriverImpl.java new file mode 100644 index 00000000..5edbeb45 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/DriverImpl.java @@ -0,0 +1,78 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +public class DriverImpl implements Driver { + + public static NoDriver noDriver(){ + return new NoDriver(); + } + + public static class NoDriver extends DriverImpl { + + public NoDriver() { + super("noDriver"); + } + + } + + private String id; + + private double earliestStart = 0.0; + + private double latestEnd = Double.MAX_VALUE; + + private String home; + + private DriverImpl(String id) { + super(); + this.id = id; + } + + public String getId() { + return id; + } + + public double getEarliestStart() { + return earliestStart; + } + + public void setEarliestStart(double earliestStart) { + this.earliestStart = earliestStart; + } + + public double getLatestEnd() { + return latestEnd; + } + + public void setLatestEnd(double latestEnd) { + this.latestEnd = latestEnd; + } + + public void setHomeLocation(String locationId) { + this.home = locationId; + } + + public String getHomeLocation() { + return this.home; + } + +} diff --git a/jsprit-core/src/main/java/basics/route/End.java b/jsprit-core/src/main/java/basics/route/End.java new file mode 100644 index 00000000..b39aead4 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/End.java @@ -0,0 +1,143 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import util.Coordinate; + +public final class End implements TourActivity { + + public static int creation = 0; + + public static End newInstance(String locationId, double earliestArrival, double latestArrival) { + creation++; + return new End(locationId,earliestArrival,latestArrival); + } + + public static End copyOf(End end){ + return new End(end); + } + + private String locationId; + + private Coordinate coordinate; + + public Coordinate getCoordinate() { + return coordinate; + } + + public void setCoordinate(Coordinate coordinate) { + this.coordinate = coordinate; + } + + private double endTime = -1; + + + private double theoretical_earliestOperationStartTime; + + private double theoretical_latestOperationStartTime; + + private double arrTime; + + public void setTheoreticalEarliestOperationStartTime(double theoreticalEarliestOperationStartTime) { + theoretical_earliestOperationStartTime = theoreticalEarliestOperationStartTime; + } + + public void setTheoreticalLatestOperationStartTime(double theoreticalLatestOperationStartTime) { + theoretical_latestOperationStartTime = theoreticalLatestOperationStartTime; + } + + public End(String locationId, double theoreticalStart, double theoreticalEnd) { + super(); + this.locationId = locationId; + theoretical_earliestOperationStartTime = theoreticalStart; + theoretical_latestOperationStartTime = theoreticalEnd; + } + + public End(End end) { + this.locationId = end.getLocationId(); + theoretical_earliestOperationStartTime = end.getTheoreticalEarliestOperationStartTime(); + theoretical_latestOperationStartTime = end.getTheoreticalLatestOperationStartTime(); + } + + public double getTheoreticalEarliestOperationStartTime() { + return theoretical_earliestOperationStartTime; + } + + public double getTheoreticalLatestOperationStartTime() { + return theoretical_latestOperationStartTime; + } + + public double getEndTime() { + return endTime; + } + + public void setEndTime(double endTime) { + this.endTime = endTime; + } + + public void setLocationId(String locationId) { + this.locationId = locationId; + } + + @Override + public String getLocationId() { + return locationId; + } + + @Override + public double getOperationTime() { + return 0.0; + } + + + @Override + public String toString() { + return "[type="+getName()+"][locationId=" + getLocationId() + + "][twStart=" + round(theoretical_earliestOperationStartTime) + + "][twEnd=" + round(theoretical_latestOperationStartTime) + "]"; + } + + private String round(double time) { + if (time == Double.MAX_VALUE) { + return "oo"; + } + return "" + Math.round(time); + } + + @Override + public String getName() { + return "end"; + } + + @Override + public double getArrTime() { + return this.arrTime; + } + + @Override + public void setArrTime(double arrTime) { + this.arrTime = arrTime; + + } + + @Override + public int getCapacityDemand() { + return 0; + } + + @Override + public TourActivity duplicate() { + return new End(this); + } + +} diff --git a/jsprit-core/src/main/java/basics/route/ServiceActivity.java b/jsprit-core/src/main/java/basics/route/ServiceActivity.java new file mode 100644 index 00000000..c93334bf --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/ServiceActivity.java @@ -0,0 +1,161 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import basics.Service; +import basics.route.TourActivity.JobActivity; + +public class ServiceActivity implements JobActivity{ + + public static int counter = 0; + + public double arrTime; + + public double endTime; + + /** + * @return the arrTime + */ + public double getArrTime() { + return arrTime; + } + + /** + * @param arrTime the arrTime to set + */ + public void setArrTime(double arrTime) { + this.arrTime = arrTime; + } + + /** + * @return the endTime + */ + public double getEndTime() { + return endTime; + } + + /** + * @param endTime the endTime to set + */ + public void setEndTime(double endTime) { + this.endTime = endTime; + } + + public static ServiceActivity copyOf(ServiceActivity serviceActivity){ + return new ServiceActivity(serviceActivity); + } + + public static ServiceActivity newInstance(Service service){ + return new ServiceActivity(service); + } + + private final Service service; + + private ServiceActivity(Service service) { + counter++; + this.service = service; + } + + private ServiceActivity(ServiceActivity serviceActivity) { + counter++; + this.service = serviceActivity.getJob(); + this.arrTime = serviceActivity.getArrTime(); + this.endTime = serviceActivity.getEndTime(); + } + + + /* (non-Javadoc) + * @see java.lang.Object#hashCode() + */ + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((service == null) ? 0 : service.hashCode()); + return result; + } + + /* (non-Javadoc) + * @see java.lang.Object#equals(java.lang.Object) + */ + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + ServiceActivity other = (ServiceActivity) obj; + if (service == null) { + if (other.service != null) + return false; + } else if (!service.equals(other.service)) + return false; + return true; + } + + public double getTheoreticalEarliestOperationStartTime() { + return service.getTimeWindow().getStart(); + } + + public double getTheoreticalLatestOperationStartTime() { + return service.getTimeWindow().getEnd(); + } + + @Override + public int getCapacityDemand() { + return service.getCapacityDemand(); + } + + @Override + public double getOperationTime() { + return service.getServiceDuration(); + } + + @Override + public String getLocationId() { + return service.getLocationId(); + } + + + @Override + public Service getJob() { + return service; + } + + public String toString() { + return "[type="+getName()+"][service="+this.service+"]"; + } + + @Override + public String getName() { + return service.getType(); + } + + @Override + public TourActivity duplicate() { + return new ServiceActivity(this); + } + + + +} diff --git a/jsprit-core/src/main/java/basics/route/Start.java b/jsprit-core/src/main/java/basics/route/Start.java new file mode 100644 index 00000000..fb284f06 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/Start.java @@ -0,0 +1,154 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import util.Coordinate; + +public final class Start implements TourActivity { + + public final static String ACTIVITY_NAME = "start"; + + public static int creation; + + public static Start newInstance(String locationId, double theoreticalStart, double theoreticalEnd){ + creation++; + return new Start(locationId,theoreticalStart,theoreticalEnd); + } + + public static Start copyOf(Start start){ + return new Start(start); + } + + private String locationId; + + + + private Coordinate coordinate; + + private double theoretical_earliestOperationStartTime; + + private double theoretical_latestOperationStartTime; + + private double endTime; + + private double arrTime; + + public Start(String locationId, double theoreticalStart, double theoreticalEnd) { + super(); + this.locationId = locationId; + this.theoretical_earliestOperationStartTime = theoreticalStart; + this.theoretical_latestOperationStartTime = theoreticalEnd; + this.endTime = theoreticalStart; + + } + + private Start(Start start) { + this.locationId = start.getLocationId(); + theoretical_earliestOperationStartTime = start.getTheoreticalEarliestOperationStartTime(); + theoretical_latestOperationStartTime = start.getTheoreticalLatestOperationStartTime(); + endTime = start.getEndTime(); + } + + + + public Coordinate getCoordinate() { + return coordinate; + } + + public void setCoordinate(Coordinate coordinate) { + this.coordinate = coordinate; + } + + public double getTheoreticalEarliestOperationStartTime() { + return theoretical_earliestOperationStartTime; + } + + public void setLocationId(String locationId) { + this.locationId = locationId; + } + + public double getTheoreticalLatestOperationStartTime() { + return theoretical_latestOperationStartTime; + } + + public void setTheoreticalEarliestOperationStartTime(double time) { + this.theoretical_earliestOperationStartTime=time; + } + + public void setTheoreticalLatestOperationStartTime(double time) { + this.theoretical_latestOperationStartTime=time; + } + + @Override + public String getLocationId() { + return locationId; + } + + @Override + public double getOperationTime() { + return 0.0; + } + + @Override + public String toString() { + return "[type="+getName()+"][locationId=" + getLocationId() + + "][twStart=" + round(theoretical_earliestOperationStartTime) + + "][twEnd=" + round(theoretical_latestOperationStartTime) + "]"; + } + + private String round(double time) { + if (time == Double.MAX_VALUE) { + return "oo"; + } + return "" + Math.round(time); + } + + + @Override + public String getName() { + return "start"; + } + + @Override + public double getArrTime() { + return arrTime; + } + + @Override + public double getEndTime() { + return endTime; + } + + @Override + public void setArrTime(double arrTime) { + this.arrTime = arrTime; + } + + @Override + public void setEndTime(double endTime) { + this.endTime = endTime; + } + + @Override + public int getCapacityDemand() { + return 0; + } + + @Override + public TourActivity duplicate() { + return new Start(this); + } + + + +} diff --git a/jsprit-core/src/main/java/basics/route/TimeWindow.java b/jsprit-core/src/main/java/basics/route/TimeWindow.java new file mode 100644 index 00000000..2a804306 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/TimeWindow.java @@ -0,0 +1,79 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +/** + * + * @author stefan schroeder + * + */ + +public class TimeWindow { + + public static TimeWindow newInstance(double start, double end){ + return new TimeWindow(start,end); + } + + private final double start; + private final double end; + + public TimeWindow(double start, double end) { + super(); + this.start = start; + this.end = end; + } + + public double getStart() { + return start; + } + + public double getEnd() { + return end; + } + + @Override + public String toString() { + return "[start=" + start + "][end=" + end + "]"; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + long temp; + temp = Double.doubleToLongBits(end); + result = prime * result + (int) (temp ^ (temp >>> 32)); + temp = Double.doubleToLongBits(start); + result = prime * result + (int) (temp ^ (temp >>> 32)); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + TimeWindow other = (TimeWindow) obj; + if (Double.doubleToLongBits(end) != Double.doubleToLongBits(other.end)) + return false; + if (Double.doubleToLongBits(start) != Double + .doubleToLongBits(other.start)) + return false; + return true; + } + + +} diff --git a/jsprit-core/src/main/java/basics/route/TourActivities.java b/jsprit-core/src/main/java/basics/route/TourActivities.java new file mode 100644 index 00000000..eed81154 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/TourActivities.java @@ -0,0 +1,204 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Iterator; +import java.util.List; +import java.util.Set; + +import basics.Job; +import basics.route.TourActivity.JobActivity; + + +/** + * + * @author stefan schroeder + * + */ + +public class TourActivities { + + public static TourActivities copyOf(TourActivities tourActivities){ + return new TourActivities(tourActivities); + } + + public static class ReverseActivityIterator implements Iterator { + + private List acts; + private int currentIndex; + + public ReverseActivityIterator(List acts) { + super(); + this.acts = acts; + currentIndex = acts.size()-1; + } + + @Override + public boolean hasNext() { + if(currentIndex >= 0) return true; + return false; + } + + @Override + public TourActivity next() { + TourActivity act = acts.get(currentIndex); + currentIndex--; + return act; + } + + public void reset(){ + currentIndex = acts.size()-1; + } + + @Override + public void remove() { + throw new UnsupportedOperationException(); + } + } + + + public static TourActivities emptyTour(){ + return new TourActivities(); + } + + private final ArrayList tourActivities = new ArrayList(); +// private final LinkedList tourActivities = new LinkedList(); +// private final TreeList tourActivities = new TreeList(); + + private final Set jobs = new HashSet(); + + private int load = 0; + + private double cost = 0.0; + + private ReverseActivityIterator backward; + + private TourActivities(TourActivities tour2copy) { + for (TourActivity tourAct : tour2copy.getActivities()) { + TourActivity newAct = tourAct.duplicate(); + this.tourActivities.add(newAct); + addJob(newAct); + } + } + + public TourActivities(){ + + } + + public List getActivities() { + return Collections.unmodifiableList(tourActivities); + } + + public Iterator iterator(){ + return tourActivities.iterator(); + } + + public boolean isEmpty() { + return (tourActivities.size() == 0); + } + + public Collection getJobs(){ + return Collections.unmodifiableSet(jobs); + } + + public boolean servesJob(Job job) { + return jobs.contains(job); + } + + @Override + public String toString() { + return "[nuOfActivities="+tourActivities.size()+"]"; + } + + /** + * Removes job AND belonging activity from tour. + * + * @param job + * @return + */ + public boolean removeJob(Job job){ + boolean jobRemoved = false; + if(!jobs.contains(job)){ + return false; + } + else{ + jobRemoved = jobs.remove(job); + } + boolean activityRemoved = false; + List acts = new ArrayList(tourActivities); + for(TourActivity c : acts){ + if(c instanceof JobActivity){ + if(job.equals(((JobActivity) c).getJob())){ + tourActivities.remove(c); + activityRemoved = true; + } + } + else if(c instanceof ServiceActivity){ + if(job.equals(((ServiceActivity) c).getJob())){ + tourActivities.remove(c); + activityRemoved = true; + } + } + } + if(jobRemoved != activityRemoved) throw new IllegalStateException("job removed, but belonging activity not."); + return activityRemoved; + } + + public void addActivity(int insertionIndex, TourActivity act) { + assert insertionIndex >= 0 : "insertionIndex == 0, this cannot be"; + /* + * if 1 --> between start and act(0) --> act(0) + * if 2 && 2 <= acts.size --> between act(0) and act(1) --> act(1) + * if 2 && 2 > acts.size --> at actEnd + * ... + * + */ + if(insertionIndex < tourActivities.size()) tourActivities.add(insertionIndex, act); + else if(insertionIndex >= tourActivities.size()) tourActivities.add(act); + addJob(act); + } + + public void addActivity(TourActivity act){ + if(tourActivities.contains(act)) throw new IllegalStateException("act " + act + " already in tour. cannot add act twice."); + tourActivities.add(act); + addJob(act); + } + + private void addJob(TourActivity act) { + + if(act instanceof JobActivity){ + Job job = ((JobActivity) act).getJob(); + jobs.add(job); + } + else if(act instanceof ServiceActivity){ + jobs.add(((ServiceActivity) act).getJob()); + } + } + + public int jobSize() { + return jobs.size(); + } + + public Iterator reverseActivityIterator(){ + if(backward == null) backward = new ReverseActivityIterator(tourActivities); + else backward.reset(); + return backward; + } + + + +} diff --git a/jsprit-core/src/main/java/basics/route/TourActivity.java b/jsprit-core/src/main/java/basics/route/TourActivity.java new file mode 100644 index 00000000..ecceb6ba --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/TourActivity.java @@ -0,0 +1,48 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import basics.Job; + + +public interface TourActivity { + + public interface JobActivity extends TourActivity { + + public T getJob(); + + } + + public int getCapacityDemand(); + + public abstract String getName(); + + public abstract String getLocationId(); + + public abstract double getTheoreticalEarliestOperationStartTime(); + + public abstract double getTheoreticalLatestOperationStartTime(); + + public abstract double getOperationTime(); + + public abstract double getArrTime(); + + public abstract double getEndTime(); + + public abstract void setArrTime(double arrTime); + + public abstract void setEndTime(double endTime); + + public TourActivity duplicate(); + +} diff --git a/jsprit-core/src/main/java/basics/route/Vehicle.java b/jsprit-core/src/main/java/basics/route/Vehicle.java new file mode 100644 index 00000000..60e8eb86 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/Vehicle.java @@ -0,0 +1,44 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import util.Coordinate; +import basics.route.VehicleImpl.VehicleType; + + + +public interface Vehicle { + + public abstract double getEarliestDeparture(); + + public abstract double getLatestArrival(); + + public abstract String getLocationId(); + + public abstract Coordinate getCoord(); + + public abstract VehicleType getType(); + + public abstract String getId(); + + public abstract int getCapacity(); + +} diff --git a/jsprit-core/src/main/java/basics/route/VehicleImpl.java b/jsprit-core/src/main/java/basics/route/VehicleImpl.java new file mode 100644 index 00000000..7708b701 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/VehicleImpl.java @@ -0,0 +1,385 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import org.apache.log4j.Logger; + +import util.Coordinate; + +/** + * + * @author stefan schroeder + * + */ + +public class VehicleImpl implements Vehicle { + + public static NoVehicle noVehicle(){ + return createNoVehicle(); + } + + public static class NoVehicle extends VehicleImpl { + + public NoVehicle() { + super(VehicleBuilder.newInstance("noVehicle").setType(VehicleType.newInstance(null, 0, null))); + } + + public int getCapacity(){ + return 0; + } + + } + + public static class VehicleType { + + public static class TimeSchedule{ + private double earliestStart; + private double latestEnd; + + public TimeSchedule(double earliestStart, double latestEnd) { + super(); + this.earliestStart = earliestStart; + this.latestEnd = latestEnd; + } + + public double getEarliestStart() { + return earliestStart; + } + + public double getLatestEnd() { + return latestEnd; + } + + + } + + public static class Builder{ + + public static Builder newInstance(String id, int capacity){ + return new Builder(id,capacity); + } + + private String id; + private int capacity; + private double fixedCost; + private double perDistance; + private double perTime; + +// private TimeSchedule timeSchedule = new TimeSchedule(0.0,Integer.MAX_VALUE); + + public Builder(String id, int capacity) { + super(); + this.id = id; + this.capacity = capacity; + } + + public Builder setFixedCost(double fixedCost) { this.fixedCost = fixedCost; return this; } + + public Builder setCostPerDistance(double perDistance){ this.perDistance = perDistance; return this; } + + public Builder setCostPerTime(double perTime){ this.perTime = perTime; return this; } + +// public Builder setTimeSchedule(TimeSchedule timeSchedule){ this.timeSchedule = timeSchedule; return this; } + + public VehicleType build(){ + return new VehicleType(this); +// return Type.newInstance(id, capacity, VehicleCostParams.newInstance(fixedCost, perTime, perDistance)); + } + + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((typeId == null) ? 0 : typeId.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + VehicleType other = (VehicleType) obj; + if (typeId == null) { + if (other.typeId != null) + return false; + } else if (!typeId.equals(other.typeId)) + return false; + return true; + } + + public final String typeId; + public final int capacity; + public final VehicleCostParams vehicleCostParams; +// private double speed = 22.0; + + private TimeSchedule timeSchedule; + + public static VehicleType newInstance(String typeId, int capacity, VehicleCostParams para){ + return new VehicleType(typeId, capacity, para); + } + + private VehicleType(Builder builder){ + typeId = builder.id; + capacity = builder.capacity; + vehicleCostParams = new VehicleCostParams(builder.fixedCost, builder.perTime, builder.perDistance); +// timeSchedule = builder.timeSchedule; + } + + public VehicleType(String typeId, int capacity,VehicleCostParams vehicleCostParams) { + super(); + this.typeId = typeId; + this.capacity = capacity; + this.vehicleCostParams = vehicleCostParams; + } + + public String getTypeId() { + return typeId; + } + + public int getCapacity() { + return capacity; + } + + @Deprecated + public TimeSchedule getTimeSchedule() { + return timeSchedule; + } + + public VehicleCostParams getVehicleCostParams() { + return vehicleCostParams; + } + +// public double getSpeed() { +// return speed; +// } +// +// public void setSpeed(double speed) { +// this.speed = speed; +// } + + @Override + public String toString() { + return "[typeId="+typeId+"][capacity="+capacity+"]" + vehicleCostParams; + } + } + + public static class VehicleCostParams { + + public static VehicleCostParams newInstance(double fix, double perTimeUnit,double perDistanceUnit){ + return new VehicleCostParams(fix, perTimeUnit, perDistanceUnit); + } + + public final double fix; + public final double perTimeUnit; + public final double perDistanceUnit; + + private VehicleCostParams(double fix, double perTimeUnit,double perDistanceUnit) { + super(); + this.fix = fix; + this.perTimeUnit = perTimeUnit; + this.perDistanceUnit = perDistanceUnit; + } + + @Override + public String toString() { + return "[fixed="+fix+"][perTime="+perTimeUnit+"][perDistance="+perDistanceUnit+"]"; + } + } + + public static class VehicleBuilder { + static Logger log = Logger.getLogger(VehicleBuilder.class); + private String id; + private VehicleType type; + private String locationId; + private Coordinate locationCoord; + private double earliestStart = 0.0; + private double latestArrival = Double.MAX_VALUE; + + private VehicleBuilder(String id) { + super(); + this.id = id; + } + + public VehicleBuilder setType(VehicleType type){ + this.type = type; + return this; + } + + public VehicleBuilder setLocationId(String id){ + this.locationId = id; + return this; + } + + public VehicleBuilder setLocationCoord(Coordinate coord){ + this.locationCoord = coord; + return this; + } + + public VehicleBuilder setEarliestStart(double start){ + this.earliestStart = start; + return this; + } + + public VehicleBuilder setLatestArrival(double arr){ + this.latestArrival = arr; + return this; + } + + public VehicleImpl build(){ + if(type == null) throw new IllegalStateException("type must not be null"); + if(locationId == null && locationCoord != null) locationId = locationCoord.toString(); + if(locationId == null && locationCoord == null) throw new IllegalStateException("locationId and locationCoord is missing."); + if(locationCoord == null) log.warn("locationCoord for vehicle " + id + " is missing."); + return new VehicleImpl(this); + } + + public static VehicleBuilder newInstance(String vehicleId){ return new VehicleBuilder(vehicleId); } + + } + + + public static NoVehicle createNoVehicle(){ + return new NoVehicle(); + } + + private final String id; + + private final VehicleType type; + + private final String locationId; + + private final Coordinate coord; + + private final double earliestDeparture; + + private final double latestArrival; + + private VehicleImpl(VehicleBuilder builder){ + id = builder.id; + type = builder.type; + coord = builder.locationCoord; + locationId = builder.locationId; + earliestDeparture = builder.earliestStart; + latestArrival = builder.latestArrival; + } + + + + @Override + public String toString() { + return "[id="+id+"][type="+type+"][locationId="+locationId+"][coord=" + coord + "]"; + } + + public Coordinate getCoord() { + return coord; + } + +// public void setCoord(Coordinate coord) { +// this.coord = coord; +// } + +// public void setLocationId(String locationId) { +// this.locationId = locationId; +// } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getEarliestDeparture() + */ + @Override + public double getEarliestDeparture() { + return earliestDeparture; + } + + /* + * (non-Javadoc) + * + * @see + * org.matsim.contrib.freight.vrp.basics.Vehicle#setEarliestDeparture(double + * ) + */ + +// public void setEarliestDeparture(double earliestDeparture) { +// this.earliestDeparture = earliestDeparture; +// } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getLatestArrival() + */ + @Override + public double getLatestArrival() { + return latestArrival; + } + + /* + * (non-Javadoc) + * + * @see + * org.matsim.contrib.freight.vrp.basics.Vehicle#setLatestArrival(double) + */ + +// public void setLatestArrival(double latestArrival) { +// this.latestArrival = latestArrival; +// } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getLocationId() + */ + @Override + public String getLocationId() { + return locationId; + } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getType() + */ + @Override + public VehicleType getType() { + return type; + } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getId() + */ + @Override + public String getId() { + return id; + } + + /* + * (non-Javadoc) + * + * @see org.matsim.contrib.freight.vrp.basics.Vehicle#getCapacity() + */ + @Override + public int getCapacity() { + return type.capacity; + } + +} diff --git a/jsprit-core/src/main/java/basics/route/VehicleRoute.java b/jsprit-core/src/main/java/basics/route/VehicleRoute.java new file mode 100644 index 00000000..e7bf3814 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/VehicleRoute.java @@ -0,0 +1,191 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import basics.route.VehicleImpl.NoVehicle; + +public class VehicleRoute { + + public static VehicleRoute copyOf(VehicleRoute route) { + return new VehicleRoute(route); + } + + public static VehicleRoute newInstance(TourActivities tour, Driver driver, Vehicle vehicle) { + return new VehicleRoute(tour,driver,vehicle); + } + + public static VehicleRoute emptyRoute() { + return new VehicleRoute(TourActivities.emptyTour(), DriverImpl.noDriver(), VehicleImpl.noVehicle()); + } + + public static class Builder { + + public static Builder newInstance(Start start, End end){ + return new Builder(start,end); + } + + private Start start; + + private End end; + + private Vehicle vehicle = VehicleImpl.noVehicle(); + + private Driver driver = DriverImpl.noDriver(); + + private TourActivities tour; + + private Builder(Start start, End end) { + super(); + this.start = start; + this.end = end; + this.tour = TourActivities.emptyTour(); + } + + public Builder setVehicle(Vehicle vehicle){ + this.vehicle = vehicle; + return this; + } + + public Builder setDriver(Driver driver){ + this.driver = driver; + return this; + } + + public Builder addActivity(TourActivity act){ + if(act instanceof Start || act instanceof End){ + throw new IllegalStateException("tourActivity should be of type Delivery or Pickup, but is of type " + act.getName()); + } + tour.addActivity(act); + return this; + } + + public VehicleRoute build(){ + return new VehicleRoute(this); + } + } + + private TourActivities tourActivities; + + private Vehicle vehicle; + + private Driver driver; + + private Start start; + + private End end; + + private VehicleRouteCostCalculator costCalculator = new DefaultVehicleRouteCostCalculator(); + + public void setVehicleRouteCostCalculator(VehicleRouteCostCalculator costAccumulator){ + this.costCalculator = costAccumulator; + } + + public VehicleRouteCostCalculator getVehicleRouteCostCalculator(){ + return costCalculator; + } + + public double getCost() { + if(tourActivities.isEmpty()){ + return 0.0; + } + return costCalculator.getCosts(); + } + + private VehicleRoute(VehicleRoute route){ + this.start = Start.copyOf(route.getStart()); + this.end = End.copyOf(route.getEnd()); + this.tourActivities = TourActivities.copyOf(route.getTourActivities()); + this.vehicle = route.getVehicle(); + this.driver = route.getDriver(); + this.costCalculator = route.getVehicleRouteCostCalculator().duplicate(); + } + + private VehicleRoute(TourActivities tour, Driver driver, Vehicle vehicle) { + super(); + verify(tour, driver, vehicle); + this.tourActivities = tour; + this.vehicle = vehicle; + this.driver = driver; + setStartAndEnd(vehicle, vehicle.getEarliestDeparture()); + } + + private VehicleRoute(Builder builder){ + this.tourActivities = builder.tour; + this.vehicle = builder.vehicle; + this.driver = builder.driver; + this.start = builder.start; + this.end = builder.end; + } + + private void verify(TourActivities tour, Driver driver, Vehicle vehicle) { + if(tour == null || driver == null || vehicle == null) throw new IllegalStateException("null is not allowed for tour, driver or vehicle. use emptyRoute. use Tour.emptyTour, DriverImpl.noDriver() and VehicleImpl.noVehicle() instead." + + "\n\tor make it easier and use VehicleRoute.emptyRoute()"); + if(!tour.isEmpty() && vehicle instanceof NoVehicle){ + throw new IllegalStateException("if tour is not empty. there must be a vehicle for this tour, but there is no vehicle."); + } + } + + public TourActivities getTourActivities() { + return tourActivities; + } + + + public Vehicle getVehicle() { + return vehicle; + } + + public Driver getDriver() { + return driver; + } + + public void setVehicle(Vehicle vehicle, double vehicleDepTime){ + this.vehicle = vehicle; + setStartAndEnd(vehicle, vehicleDepTime); + } + + public void setDepartureTime(double vehicleDepTime){ + if(start == null) throw new IllegalStateException("cannot set departureTime without having a vehicle on this route. use setVehicle(vehicle,departureTime) instead."); + start.setEndTime(vehicleDepTime); + } + + private void setStartAndEnd(Vehicle vehicle, double vehicleDepTime) { + if(!(vehicle instanceof NoVehicle)){ + if(start == null && end == null){ + start = Start.newInstance(vehicle.getLocationId(), vehicle.getEarliestDeparture(), vehicle.getLatestArrival()); + end = End.newInstance(vehicle.getLocationId(), vehicle.getEarliestDeparture(), vehicle.getLatestArrival()); + } + start.setEndTime(vehicleDepTime); + start.setTheoreticalEarliestOperationStartTime(vehicle.getEarliestDeparture()); + start.setTheoreticalLatestOperationStartTime(vehicle.getLatestArrival()); + start.setLocationId(vehicle.getLocationId()); + end.setLocationId(vehicle.getLocationId()); + end.setTheoreticalEarliestOperationStartTime(vehicle.getEarliestDeparture()); + end.setTheoreticalLatestOperationStartTime(vehicle.getLatestArrival()); + } + + } + + + public boolean isEmpty() { + return tourActivities.isEmpty(); + } + + public Start getStart() { + return start; + } + + public End getEnd() { + return end; + } + +} diff --git a/jsprit-core/src/main/java/basics/route/VehicleRouteCostCalculator.java b/jsprit-core/src/main/java/basics/route/VehicleRouteCostCalculator.java new file mode 100644 index 00000000..5d956265 --- /dev/null +++ b/jsprit-core/src/main/java/basics/route/VehicleRouteCostCalculator.java @@ -0,0 +1,44 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + + +public interface VehicleRouteCostCalculator { + + public void addTransportCost(double cost); + + public void addActivityCost(double cost); + + public void addOtherCost(double cost); + + public void price(Vehicle vehicle); + + public void price(Driver driver); + + public double getCosts(); + + public void finish(); + + public void reset(); + + public VehicleRouteCostCalculator duplicate(); + +} diff --git a/jsprit-core/src/main/java/util/ArrayUtils.java b/jsprit-core/src/main/java/util/ArrayUtils.java new file mode 100644 index 00000000..a57317b2 --- /dev/null +++ b/jsprit-core/src/main/java/util/ArrayUtils.java @@ -0,0 +1,33 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.List; + +public class ArrayUtils { + + public static double[] toPrimitiveArray(List list){ + double[] arr = new double[list.size()]; + for(int i=0;i>> 32)); + temp = Double.doubleToLongBits(y); + result = prime * result + (int) (temp ^ (temp >>> 32)); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + Coordinate other = (Coordinate) obj; + if (Double.doubleToLongBits(x) != Double.doubleToLongBits(other.x)) + return false; + if (Double.doubleToLongBits(y) != Double.doubleToLongBits(other.y)) + return false; + return true; + } + +} diff --git a/jsprit-core/src/main/java/util/Counter.java b/jsprit-core/src/main/java/util/Counter.java new file mode 100644 index 00000000..977b317f --- /dev/null +++ b/jsprit-core/src/main/java/util/Counter.java @@ -0,0 +1,73 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.concurrent.atomic.AtomicLong; + +import org.apache.log4j.Logger; + + +/** + * Counter which is a copy of Counter.java at package org.matsim.core.utils.misc (www.matsim.org); + * + * @author Schroeder + * + */ + + +public final class Counter { + private final String prefix; + private AtomicLong counter = new AtomicLong(0); + private AtomicLong nextCounter = new AtomicLong(1); + private static final Logger log = Logger.getLogger(Counter.class); + + /** + * @param prefix Some text that is output just before the counter-value. + */ + public Counter(final String prefix) { + this.prefix = prefix; + } + + public void incCounter() { + long i = this.counter.incrementAndGet(); + long n = this.nextCounter.get(); + if (i >= n) { + if (this.nextCounter.compareAndSet(n, n*2)) { + log.info(this.prefix + n); + } + } + } + + public void printCounter() { + log.info(this.prefix + this.counter.get()); + } + + public long getCounter() { + return this.counter.get(); + } + + public void reset() { + this.counter.set(0); + this.nextCounter.set(1); + } +} + + diff --git a/jsprit-core/src/main/java/util/CrowFlyCosts.java b/jsprit-core/src/main/java/util/CrowFlyCosts.java new file mode 100644 index 00000000..ce4e290c --- /dev/null +++ b/jsprit-core/src/main/java/util/CrowFlyCosts.java @@ -0,0 +1,77 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +/** + * + */ +package util; + +import org.apache.log4j.Logger; + +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleImpl.VehicleType; + + +/** + * @author stefan schroeder + * + */ +public class CrowFlyCosts implements VehicleRoutingTransportCosts { + + private static Logger logger = Logger.getLogger(CrowFlyCosts.class); + + public int speed = 1; + + public double detourFactor = 1.0; + + private Locations locations; + + public CrowFlyCosts(Locations locations) { + super(); + this.locations = locations; + } + + @Override + public String toString() { + return "[name=crowFlyCosts]"; + } + + @Override + public double getTransportCost(String fromId, String toId, double time, Driver driver, Vehicle vehicle) { + double cost; + try { + cost = EuclideanDistanceCalculator.calculateDistance(locations.getCoord(fromId), locations.getCoord(toId)) * detourFactor; + } catch (NullPointerException e) { + throw new NullPointerException("cannot calculate euclidean distance. coordinates are missing. either add coordinates or use another transport-cost-calculator."); + } + return cost; + } + + @Override + public double getTransportTime(String fromId, String toId, double time, Driver driver, Vehicle vehicle) { + double transportTime = getTransportCost(fromId, toId, 0.0, null, null) / speed; + return transportTime; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, arrivalTime, null, null); + } + + @Override + public double getBackwardTransportTime(String fromId, String toId, double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportTime(fromId, toId, arrivalTime, null, null); + } + +} diff --git a/jsprit-core/src/main/java/util/EuclideanDistanceCalculator.java b/jsprit-core/src/main/java/util/EuclideanDistanceCalculator.java new file mode 100644 index 00000000..e19cda72 --- /dev/null +++ b/jsprit-core/src/main/java/util/EuclideanDistanceCalculator.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + + + +public class EuclideanDistanceCalculator { + + public static double calculateDistance(Coordinate coord1, Coordinate coord2) { + double xDiff = coord1.getX() - coord2.getX(); + double yDiff = coord1.getY() - coord2.getY(); + return Math.sqrt((xDiff * xDiff) + (yDiff * yDiff)); + } + +} diff --git a/jsprit-core/src/main/java/util/Locations.java b/jsprit-core/src/main/java/util/Locations.java new file mode 100644 index 00000000..b07d4ee6 --- /dev/null +++ b/jsprit-core/src/main/java/util/Locations.java @@ -0,0 +1,22 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + + + + +public interface Locations { + + public abstract Coordinate getCoord(String id); + +} diff --git a/jsprit-core/src/main/java/util/ManhattanCosts.java b/jsprit-core/src/main/java/util/ManhattanCosts.java new file mode 100644 index 00000000..473a1ab4 --- /dev/null +++ b/jsprit-core/src/main/java/util/ManhattanCosts.java @@ -0,0 +1,71 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + + + +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.Vehicle; + +/** + * + * @author stefan schroeder + * + */ + +public class ManhattanCosts implements VehicleRoutingTransportCosts { + + public double speed = 1; + + private Locations locations; + + public ManhattanCosts(Locations locations) { + super(); + this.locations = locations; + } + + @Override + public double getTransportCost(String fromId, String toId, double time, + Driver driver, Vehicle vehicle) { + return calculateDistance(fromId, toId); + } + + @Override + public double getTransportTime(String fromId, String toId, double time, + Driver driver, Vehicle vehicle) { + double transportTime = calculateDistance(fromId, toId) / speed; + return transportTime; + } + + private double calculateDistance(String fromId, String toId) { + double distance = Math.abs(locations.getCoord(fromId).getX() + - locations.getCoord(toId).getX()) + + Math.abs(locations.getCoord(fromId).getY() + - locations.getCoord(toId).getY()); + return distance; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, arrivalTime, null, null); + } + + @Override + public double getBackwardTransportTime(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportTime(fromId, toId, arrivalTime, null, null); + } + +} diff --git a/jsprit-core/src/main/java/util/ManhattanDistanceCalculator.java b/jsprit-core/src/main/java/util/ManhattanDistanceCalculator.java new file mode 100644 index 00000000..d9398a68 --- /dev/null +++ b/jsprit-core/src/main/java/util/ManhattanDistanceCalculator.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + + + +public class ManhattanDistanceCalculator { + + public static double calculateDistance(Coordinate coord1, Coordinate coord2) { + double distance = Math.abs(coord1.getX() - coord2.getX()) + + Math.abs(coord1.getY() - coord2.getY()); + return distance; + } + +} diff --git a/jsprit-core/src/main/java/util/Neighborhood.java b/jsprit-core/src/main/java/util/Neighborhood.java new file mode 100644 index 00000000..9b32ce16 --- /dev/null +++ b/jsprit-core/src/main/java/util/Neighborhood.java @@ -0,0 +1,27 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +public interface Neighborhood { + + public boolean areNeighbors(String location1, String location2); + +} diff --git a/jsprit-core/src/main/java/util/NeighborhoodImpl.java b/jsprit-core/src/main/java/util/NeighborhoodImpl.java new file mode 100644 index 00000000..2be36117 --- /dev/null +++ b/jsprit-core/src/main/java/util/NeighborhoodImpl.java @@ -0,0 +1,119 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; +import java.util.Set; +import org.apache.log4j.Logger; + +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.route.Vehicle; + + + +public class NeighborhoodImpl implements Neighborhood{ + + private static Logger log = Logger.getLogger(NeighborhoodImpl.class); + + private Set neighborsToAll; + + private double threshold = Double.MAX_VALUE; + + private boolean initialised = false; + + private VehicleRoutingProblem vrp; + + public void setThreshold(double threshold) { + this.threshold = threshold; + log.info("set threshold to " + threshold); + } + + private Map> neighbors; + + public NeighborhoodImpl(VehicleRoutingProblem vrp) { + neighborsToAll = new HashSet(); + this.vrp = vrp; + neighbors = new HashMap>(); +// makeNeighbors(); + } + + private void makeNeighbors() { + for(Job i : vrp.getJobs().values()){ + Set neigh = new HashSet(); + for(Vehicle v : vrp.getVehicles()){ + double dist2depot = EuclideanDistanceCalculator.calculateDistance(v.getCoord(), ((Service)i).getCoord()); + if(dist2depot <= threshold){ + neighborsToAll.add(((Service)i).getLocationId()); + } + } + for(Job j : vrp.getJobs().values()){ + double crowFlyDistance = EuclideanDistanceCalculator.calculateDistance(((Service)i).getCoord(), ((Service)j).getCoord()); + + if(crowFlyDistance <= threshold) { + neigh.add(((Service)j).getLocationId()); + } + } + neighbors.put(((Service)i).getLocationId(), neigh); + } + + } + + private void makeNeighborsToAll(Collection vehicles) { + for(Vehicle v : vehicles){ + neighborsToAll.add(v.getLocationId()); + } +// for(Job j : vrp.getJobs().values()){ +// +// } + } + + public void initialise(){ + log.info("initialise neighboorhood [threshold="+ this.threshold + "]"); + makeNeighborsToAll(vrp.getVehicles()); + makeNeighbors(); + initialised = true; + } + + public boolean areNeighbors(String location1, String location2){ + if(!initialised) { +// initialise(); + return true; + } + if(neighborsToAll.contains(location1) || neighborsToAll.contains(location2)){ + return true; + } + if(neighbors.get(location1).contains(location2)){ + return true; + } + return false; + } + + @Override + public String toString() { + return "[name=euclideanNeighborhood][threshold="+threshold+"]"; + } + +} diff --git a/jsprit-core/src/main/java/util/RandomNumberGeneration.java b/jsprit-core/src/main/java/util/RandomNumberGeneration.java new file mode 100644 index 00000000..074e7563 --- /dev/null +++ b/jsprit-core/src/main/java/util/RandomNumberGeneration.java @@ -0,0 +1,35 @@ +/******************************************************************************* + * Copyright (c) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the GNU Public License v2.0 + * which accompanies this distribution, and is available at + * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.Random; + +public class RandomNumberGeneration { + + private static long DEFAULT_SEED = 4711L; + + private static Random random = new Random(DEFAULT_SEED); + + public static Random getRandom() { + return random; + } + + public static void setSeed(long seed) { + random.setSeed(seed); + } + + public static void reset() { + random.setSeed(DEFAULT_SEED); + } + +} diff --git a/jsprit-core/src/main/java/util/RouteUtils.java b/jsprit-core/src/main/java/util/RouteUtils.java new file mode 100644 index 00000000..fd7b3df7 --- /dev/null +++ b/jsprit-core/src/main/java/util/RouteUtils.java @@ -0,0 +1,102 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.Collection; + +import basics.route.TourActivity; +import basics.route.VehicleRoute; + + + + +public class RouteUtils { + +// public static double getTransportCosts(Collection routes) { +// double cost = 0.0; +// for (VehicleRoute r : routes) { +// if(r.getTour().isEmpty()){ +// continue; +// } +// cost += r.getTour().tourData.transportCosts; +// } +// return cost; +// } +// +// public static double getTransportTime(Collection routes) { +// double time = 0.0; +// for (VehicleRoute r : routes) { +// if(r.getTour().isEmpty()){ +// continue; +// } +// time += r.getTour().tourData.transportTime; +// } +// return time; +// } + + public static double getTotalCost(Collection routes){ + double total = 0.0; + for (VehicleRoute r : routes) { + if(r.isEmpty()) { + total += 0.0; + } + else total += r.getCost(); + } + return total; + } + + + public static double getTotalServiceTime(Collection routes){ + double total = 0.0; + for (VehicleRoute r : routes) { + if(r.getTourActivities().isEmpty()){ + continue; + } + for(TourActivity act : r.getTourActivities().getActivities()){ + total += act.getOperationTime(); + } + } + return total; + } + + + public static double getTotalFixCost(Collection routes){ + double total = 0.0; + for (VehicleRoute r : routes) { + if(r.getTourActivities().isEmpty()){ + continue; + } + total += r.getVehicle().getType().vehicleCostParams.fix; + } + return total; + } + + public static int getNuOfActiveRoutes(Collection routes){ + int count = 0; + for (VehicleRoute r : routes) { + if(r.isEmpty()){ + continue; + } + count++; + } + return count; + } +} diff --git a/jsprit-core/src/main/java/util/Solutions.java b/jsprit-core/src/main/java/util/Solutions.java new file mode 100644 index 00000000..7af2493b --- /dev/null +++ b/jsprit-core/src/main/java/util/Solutions.java @@ -0,0 +1,38 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.Collection; + +import basics.VehicleRoutingProblemSolution; + +public class Solutions { + + public static VehicleRoutingProblemSolution getBest(Collection solutions){ + VehicleRoutingProblemSolution best = null; + for(VehicleRoutingProblemSolution s : solutions){ + if(best == null) best = s; + else if(s.getCost() < best.getCost()) best = s; + } + return best; + } + +} diff --git a/jsprit-core/src/main/java/util/StopWatch.java b/jsprit-core/src/main/java/util/StopWatch.java new file mode 100644 index 00000000..54375dbf --- /dev/null +++ b/jsprit-core/src/main/java/util/StopWatch.java @@ -0,0 +1,59 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import org.apache.log4j.Logger; + +public class StopWatch { + + private static Logger log = Logger.getLogger(StopWatch.class); + + private double ran; + + private double startTime; + + public double getCompTimeInSeconds(){ + return (ran)/1000.0; + } + + public void stop(){ + ran += System.currentTimeMillis() - startTime; + } + + public void start(){ + startTime = System.currentTimeMillis(); + } + + public void reset(){ + startTime = 0; + ran = 0; + } + + @Override + public String toString() { + return getCompTimeInSeconds() + " sec"; + } + + public double getCurrTimeInSeconds() { + return (System.currentTimeMillis()-startTime)/1000.0; + } + +} diff --git a/jsprit-core/src/main/java/util/VrpVerifier.java b/jsprit-core/src/main/java/util/VrpVerifier.java new file mode 100644 index 00000000..96025820 --- /dev/null +++ b/jsprit-core/src/main/java/util/VrpVerifier.java @@ -0,0 +1,99 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package util; + +import java.util.Collection; +import java.util.HashSet; +import java.util.Set; + +import org.apache.log4j.Logger; + +import basics.Job; +import basics.Service; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.AlgorithmStartsListener; +import basics.route.DriverImpl; +import basics.route.Vehicle; + +public class VrpVerifier implements AlgorithmStartsListener{ + + private static Logger log = Logger.getLogger(VrpVerifier.class); + + private boolean hardTimeWindows = true; + + @Override + public void informAlgorithmStarts(VehicleRoutingProblem problem, VehicleRoutingAlgorithm algorithm, Collection solutions) { + //check capacity + log.info("verifying vehicle-routing-problem ..."); + log.info("check vehicle capacities ..."); + Vehicle vehicleWithMaxCapacity = getMaxVehicle(problem); + if(vehicleWithMaxCapacity == null) throw new IllegalStateException("vehicles are missing."); + for(Job j : problem.getJobs().values()){ + if(vehicleWithMaxCapacity.getCapacity() < Math.abs(j.getCapacityDemand())){ + throw new IllegalStateException("maximal vehicle-capacity is "+vehicleWithMaxCapacity.getCapacity() + ", but there is a job bigger than this. [job=" + j + "]"); + } + } + log.info("ok"); + log.info("check vehicles can manage shuttle tours ..."); + for(Job j : problem.getJobs().values()){ + Service s = (Service)j; + boolean jobCanBeRoutedWithinTimeWindow = false; + for(Vehicle v : problem.getVehicles()){ + double transportCost = problem.getTransportCosts().getTransportCost(v.getLocationId(), s.getLocationId(), v.getEarliestDeparture(), DriverImpl.noDriver(), v); + double transportTime = problem.getTransportCosts().getTransportTime(v.getLocationId(), s.getLocationId(), v.getEarliestDeparture(), DriverImpl.noDriver(), v); + if(transportTime+v.getEarliestDeparture() < s.getTimeWindow().getEnd()){ + jobCanBeRoutedWithinTimeWindow = true; + break; + } + else{ + log.warn("vehicle " + v + " needs " + transportTime + " time-units to get to " + s.getLocationId() + ". latestOperationStartTime however is " + s.getTimeWindow().getEnd()); + } + + } + if(!jobCanBeRoutedWithinTimeWindow){ + throw new IllegalStateException("no vehicle is able to cover the distance from depot to " + s.getLocationId() + " to meet the time-window " + s.getTimeWindow() + "."); + } + } + log.info("ok"); + log.info("verifying done"); + } + + public void verify(VehicleRoutingProblem pblm, VehicleRoutingAlgorithm vra){ + informAlgorithmStarts(pblm, vra, null); + } + + private Vehicle getMaxVehicle(VehicleRoutingProblem problem) { + Vehicle maxVehicle = null; + for(Vehicle v : problem.getVehicles()){ + if(maxVehicle == null) { + maxVehicle = v; + continue; + } + else if(v.getCapacity() > maxVehicle.getCapacity()){ + maxVehicle = v; + } + } + return maxVehicle; + } + +} diff --git a/jsprit-core/src/main/resources/algorithm_schema.xsd b/jsprit-core/src/main/resources/algorithm_schema.xsd new file mode 100644 index 00000000..2140340d --- /dev/null +++ b/jsprit-core/src/main/resources/algorithm_schema.xsd @@ -0,0 +1,206 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/src/main/resources/config.xml b/jsprit-core/src/main/resources/config.xml new file mode 100755 index 00000000..968dd084 --- /dev/null +++ b/jsprit-core/src/main/resources/config.xml @@ -0,0 +1,87 @@ + + + + + + 2000 + + + + + + + + 3 + + + + + + + + + 0.5 + + + + 0.5 + + + + + + + + + 0.3 + euclid + + + + 0.5 + + + + + + + + + + + --> + + + + + + + + + + diff --git a/jsprit-core/src/main/resources/log4j.xml b/jsprit-core/src/main/resources/log4j.xml new file mode 100644 index 00000000..104b01f5 --- /dev/null +++ b/jsprit-core/src/main/resources/log4j.xml @@ -0,0 +1,39 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/src/main/resources/randomWalk.xml b/jsprit-core/src/main/resources/randomWalk.xml new file mode 100755 index 00000000..3edd914e --- /dev/null +++ b/jsprit-core/src/main/resources/randomWalk.xml @@ -0,0 +1,66 @@ + + + + + + + + + + 1 + + + + + + + + 0.5 + + + + + + 0.5 + + + + + + + + + 0.3 + + + + + + 0.5 + + + + + + + diff --git a/jsprit-core/src/main/resources/schrimpf.xml b/jsprit-core/src/main/resources/schrimpf.xml new file mode 100755 index 00000000..1d5e1ecc --- /dev/null +++ b/jsprit-core/src/main/resources/schrimpf.xml @@ -0,0 +1,71 @@ + + + + + 2000 + + + + + + + 1 + + + + + 0.4 + 100 + + + + + 0.5 + + + + + + 0.5 + + + + + + + + + 0.3 + + + + + + 0.5 + + + + + + + diff --git a/jsprit-core/src/main/resources/vrp_xml_schema.xsd b/jsprit-core/src/main/resources/vrp_xml_schema.xsd new file mode 100644 index 00000000..a9508813 --- /dev/null +++ b/jsprit-core/src/main/resources/vrp_xml_schema.xsd @@ -0,0 +1,203 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/src/test/java/algorithms/AlgorithmsSuite.java b/jsprit-core/src/test/java/algorithms/AlgorithmsSuite.java new file mode 100644 index 00000000..5f56ea60 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/AlgorithmsSuite.java @@ -0,0 +1,52 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.junit.runner.RunWith; +import org.junit.runners.Suite; + +import algorithms.acceptors.AcceptNewRemoveWorstTest; +import algorithms.selectors.SelectBestTest; +import algorithms.selectors.SelectRandomlyTest; + + + +@RunWith(Suite.class) +@Suite.SuiteClasses({ + CalcVehicleTypeDependentServiceInsertionTest.class, +// FindCheaperVehicleTest.class, + GendreauPostOptTest.class, + TestAlgorithmReader.class, +// TestAux.class, + TestCalculatesActivityInsertion.class, + TestCalculatesServiceInsertion.class, + TestCalculatesServiceInsertionOnRouteLevel.class, + + TestJobDistanceAvgCosts.class, + TestTourStateUpdaterWithService.class, + + SelectBestTest.class, + SelectRandomlyTest.class, + AcceptNewRemoveWorstTest.class, +// TestUpdateTourStatesForwardInTime.class + +}) +public class AlgorithmsSuite {} diff --git a/jsprit-core/src/test/java/algorithms/CalcVehicleTypeDependentServiceInsertionTest.java b/jsprit-core/src/test/java/algorithms/CalcVehicleTypeDependentServiceInsertionTest.java new file mode 100644 index 00000000..7f2ca681 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/CalcVehicleTypeDependentServiceInsertionTest.java @@ -0,0 +1,106 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertThat; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.Arrays; + +import org.junit.Before; +import org.junit.Test; + +import algorithms.VehicleFleetManager.TypeKey; +import basics.Service; +import basics.route.TimeWindow; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleRoute; + + + + + +public class CalcVehicleTypeDependentServiceInsertionTest { + + Vehicle veh1; + Vehicle veh2; + VehicleFleetManager fleetManager; + Service service; + VehicleRoute vehicleRoute; + + @Before + public void doBefore(){ + veh1 = mock(Vehicle.class); + veh2 = mock(Vehicle.class); + when(veh1.getType()).thenReturn(VehicleImpl.VehicleType.Builder.newInstance("type1", 0).build()); + when(veh2.getType()).thenReturn(VehicleImpl.VehicleType.Builder.newInstance("type2", 0).build()); + when(veh1.getLocationId()).thenReturn("loc1"); + when(veh2.getLocationId()).thenReturn("loc2"); + fleetManager = mock(VehicleFleetManager.class); + service = mock(Service.class); + vehicleRoute = mock(VehicleRoute.class); + TypeKey typeKey1 = new TypeKey(veh1.getType(),veh1.getLocationId()); + TypeKey typeKey2 = new TypeKey(veh2.getType(),veh2.getLocationId()); + when(fleetManager.getAvailableVehicleTypes()).thenReturn(Arrays.asList(typeKey1,typeKey2)); + when(fleetManager.getEmptyVehicle(typeKey1)).thenReturn(veh1); + when(fleetManager.getEmptyVehicle(typeKey2)).thenReturn(veh2); + + when(veh1.getCapacity()).thenReturn(10); + when(veh2.getCapacity()).thenReturn(10); + + when(service.getCapacityDemand()).thenReturn(0); + when(service.getTimeWindow()).thenReturn(TimeWindow.newInstance(0.0, Double.MAX_VALUE)); + + when(vehicleRoute.getDriver()).thenReturn(null); + when(vehicleRoute.getVehicle()).thenReturn(VehicleImpl.createNoVehicle()); + } + + @Test + public void whenHaving2Vehicle_calcInsertionOfCheapest(){ + JobInsertionCalculator calc = mock(JobInsertionCalculator.class); + InsertionData iDataVeh1 = new InsertionData(10.0,InsertionData.NO_INDEX, 1, veh1, null); + InsertionData iDataVeh2 = new InsertionData(20.0,InsertionData.NO_INDEX, 1, veh2, null); + when(calc.calculate(vehicleRoute, service, veh1, veh1.getEarliestDeparture(), null, Double.MAX_VALUE)).thenReturn(iDataVeh1); + when(calc.calculate(vehicleRoute, service, veh2, veh2.getEarliestDeparture(), null, Double.MAX_VALUE)).thenReturn(iDataVeh2); + when(calc.calculate(vehicleRoute, service, veh2, veh2.getEarliestDeparture(), null, 10.0)).thenReturn(iDataVeh2); + CalculatesVehTypeDepServiceInsertion insertion = new CalculatesVehTypeDepServiceInsertion(fleetManager,calc); + InsertionData iData = insertion.calculate(vehicleRoute, service, null, 0.0, null, Double.MAX_VALUE); + assertThat(iData.getSelectedVehicle(), is(veh1)); + + } + + @Test + public void whenHaving2Vehicle_calcInsertionOfCheapest2(){ + JobInsertionCalculator calc = mock(JobInsertionCalculator.class); + InsertionData iDataVeh1 = new InsertionData(20.0,InsertionData.NO_INDEX, 1, veh1, null); + InsertionData iDataVeh2 = new InsertionData(10.0,InsertionData.NO_INDEX, 1, veh2, null); + when(calc.calculate(vehicleRoute, service, veh1, veh1.getEarliestDeparture(), null, Double.MAX_VALUE)).thenReturn(iDataVeh1); + when(calc.calculate(vehicleRoute, service, veh2, veh2.getEarliestDeparture(), null, Double.MAX_VALUE)).thenReturn(iDataVeh2); + when(calc.calculate(vehicleRoute, service, veh2, veh2.getEarliestDeparture(), null, 20.0)).thenReturn(iDataVeh2); + CalculatesVehTypeDepServiceInsertion insertion = new CalculatesVehTypeDepServiceInsertion(fleetManager,calc); + InsertionData iData = insertion.calculate(vehicleRoute, service, null, 0.0, null, Double.MAX_VALUE); + assertThat(iData.getSelectedVehicle(), is(veh2)); + + } +} diff --git a/jsprit-core/src/test/java/algorithms/CalcWithTimeSchedulingTest.java b/jsprit-core/src/test/java/algorithms/CalcWithTimeSchedulingTest.java new file mode 100644 index 00000000..f54c9c53 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/CalcWithTimeSchedulingTest.java @@ -0,0 +1,94 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; + +import java.util.Collection; + +import util.Coordinate; +import util.Solutions; +import algorithms.selectors.SelectBest; +import basics.Service; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; +import basics.VehicleRoutingProblemSolution; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + +public class CalcWithTimeSchedulingTest { + + + public void timeScheduler(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.Builder.newInstance(); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("myVehicle").setEarliestStart(0.0).setLatestArrival(100.0). + setLocationCoord(Coordinate.newInstance(0, 0)).setLocationId("0,0") + .setType(VehicleType.Builder.newInstance("myType", 20).setCostPerDistance(1.0).build()).build(); + vrpBuilder.addVehicle(vehicle); + vrpBuilder.addService(Service.Builder.newInstance("myService", 2).setLocationId("0,20").setCoord(Coordinate.newInstance(0, 20)).build()); + vrpBuilder.setFleetSize(FleetSize.INFINITE); + VehicleRoutingProblem vrp = vrpBuilder.build(); + vrp.setTransportCosts(getTpCosts(vrp.getTransportCosts())); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/testConfig.xml"); + Collection solutions = vra.searchSolutions(); + + VehicleRoutingProblemSolution sol = Solutions.getBest(solutions); + assertEquals(40.0,sol.getCost(),0.01); + assertEquals(1, sol.getRoutes().size()); + VehicleRoute route = sol.getRoutes().iterator().next(); + assertEquals(50.0,route.getStart().getEndTime(),0.01); + } + + private VehicleRoutingTransportCosts getTpCosts(final VehicleRoutingTransportCosts baseCosts) { + return new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportCost(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, arrivalTime, driver, vehicle); + } + + @Override + public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + if(departureTime < 50){ + return baseCosts.getTransportCost(fromId, toId, departureTime, driver, vehicle)*2.0; + } + return baseCosts.getTransportCost(fromId, toId, departureTime, driver, vehicle); + } + + @Override + public double getBackwardTransportTime(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportTime(fromId, toId, arrivalTime, driver, vehicle); + } + + @Override + public double getTransportTime(String fromId, String toId,double departureTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, departureTime, driver, vehicle); + } + }; + } + +} diff --git a/jsprit-core/src/test/java/algorithms/ExampleActivityCostFunction.java b/jsprit-core/src/test/java/algorithms/ExampleActivityCostFunction.java new file mode 100644 index 00000000..2cd3b699 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/ExampleActivityCostFunction.java @@ -0,0 +1,66 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import basics.costs.VehicleRoutingActivityCosts; +import basics.costs.VehicleRoutingActivityCosts.Time; +import basics.route.Driver; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.TourActivity.JobActivity; + + +public class ExampleActivityCostFunction implements VehicleRoutingActivityCosts{ + + public ExampleActivityCostFunction() { + super(); + } + + public double parameter_timeAtAct; + + public double parameter_penaltyTooLate; + + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + if(arrivalTime == Time.TOURSTART || arrivalTime == Time.UNDEFINED ){ + return 0.0; + } + else{ + //waiting + act-time + double endTime = Math.max(arrivalTime, tourAct.getTheoreticalEarliestOperationStartTime()) + tourAct.getOperationTime(); + double timeAtAct = endTime - arrivalTime; + + double totalCost = timeAtAct * parameter_timeAtAct; + + //penalty tooLate + if(tourAct instanceof JobActivity){ + if(arrivalTime > tourAct.getTheoreticalLatestOperationStartTime()){ + double penTime = arrivalTime - tourAct.getTheoreticalLatestOperationStartTime(); + totalCost += penTime * parameter_penaltyTooLate; + } + } + return totalCost; + + } + } + +} diff --git a/jsprit-core/src/test/java/algorithms/FindCheaperVehicleTest.java b/jsprit-core/src/test/java/algorithms/FindCheaperVehicleTest.java new file mode 100644 index 00000000..71647588 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/FindCheaperVehicleTest.java @@ -0,0 +1,259 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +//package algorithms; +// +//import static org.hamcrest.CoreMatchers.is; +//import static org.junit.Assert.assertThat; +// +//import java.util.ArrayList; +//import java.util.Collection; +// +//import org.junit.Before; +//import org.junit.Test; +// +//import util.ManhattanDistanceCalculator; +//import algorithms.FindCheaperVehicleAlgo; +//import algorithms.TourStateUpdater; +//import basics.Coordinate; +//import basics.Driver; +//import basics.Service; +//import basics.TimeWindow; +//import basics.Tour; +//import basics.TourBuilder; +//import basics.Vehicle; +//import basics.VehicleFleetManager; +//import basics.VehicleFleetManagerImpl; +//import basics.VehicleImpl; +//import basics.VehicleRoute; +//import basics.VehicleRoutingCosts; +//import basics.VehicleImpl.Type; +// +// +//public class FindCheaperVehicleTest { +// +// Tour tour; +// +// Vehicle heavyVehicle; +// +// Vehicle lightVehicle; +// +// VehicleRoutingCosts cost; +// +// @Before +// public void setUp(){ +// +// cost = new VehicleRoutingCosts() { +// +// @Override +// public double getBackwardTransportTime(String fromId, String toId, +// double arrivalTime, Driver driver, Vehicle vehicle) { +// // TODO Auto-generated method stub +// return 0; +// } +// +// @Override +// public double getBackwardTransportCost(String fromId, String toId, +// double arrivalTime, Driver driver, Vehicle vehicle) { +// // TODO Auto-generated method stub +// return 0; +// } +// +// @Override +// public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// +// String[] fromTokens = fromId.split(","); +// String[] toTokens = toId.split(","); +// double fromX = Double.parseDouble(fromTokens[0]); +// double fromY = Double.parseDouble(fromTokens[1]); +// +// double toX = Double.parseDouble(toTokens[0]); +// double toY = Double.parseDouble(toTokens[1]); +// +// return vehicle.getType().vehicleCostParams.perDistanceUnit*ManhattanDistanceCalculator.calculateDistance(new Coordinate(fromX, fromY), new Coordinate(toX, toY)); +// } +// +// @Override +// public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// return 0; +// } +// }; +// +// Type lightType = VehicleImpl.TypeBuilder.newInstance().setId("light").setCapacity(10).setFixedCost(1.0).setCostPerDistance(1.0).build(); +// lightVehicle = VehicleImpl.VehicleBuilder.newInstance("light").setLocationId("0,0").setType(lightType).build(); +// +// Type heavyType = VehicleImpl.TypeBuilder.newInstance().setId("heavy").setCapacity(10).setFixedCost(2.0).setCostPerDistance(2.0).build(); +// heavyVehicle = VehicleImpl.VehicleBuilder.newInstance("heavy").setLocationId("0,0").setType(heavyType).build(); +// } +// +// @Test +// public void runCheaperVehicle_lightIsCheaperThanHeavy_changeVehicle(){ +// TourStateUpdater tourStateCalculator = new TourStateUpdater(cost, new ExampleTransportCostFunction()); +// +// TourBuilder tourBuilder = new TourBuilder(); +// Service firstShipment = getService("10,0"); +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.scheduleDeliveryService(firstShipment); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// Tour tour = tourBuilder.build(); +// +// VehicleRoute route = new VehicleRoute(tour,new Driver(){},heavyVehicle); +// tourStateCalculator.updateTour(route); +// +// Collection vehicles = new ArrayList(); +// vehicles.add(lightVehicle); +// vehicles.add(heavyVehicle); +// VehicleFleetManager fleetManager = new VehicleFleetManagerImpl(vehicles); +// fleetManager.lock(heavyVehicle); +// +// FindCheaperVehicleAlgo findCheaperVehicle = new FindCheaperVehicleAlgo(fleetManager, tourStateCalculator); +// VehicleRoute newRoute = findCheaperVehicle.runAndGetVehicleRoute(route); +// +// assertThat(lightVehicle, is(newRoute.getVehicle())); +// } +// +// @Test +// public void runCheaperVehicle_costComparisonBetweenHeavyAndLight_keepHeavy(){ +// +// +// Type lightType = VehicleImpl.TypeBuilder.newInstance().setId("light").setCapacity(10).setFixedCost(1.0).setCostPerDistance(1.0).build(); +// lightVehicle = VehicleImpl.VehicleBuilder.newInstance("light").setLocationId("0,0").setType(lightType).build(); +// +// Type heavyType = VehicleImpl.TypeBuilder.newInstance().setId("heavy").setCapacity(10).setFixedCost(2.0).setCostPerDistance(1.0).build(); +// heavyVehicle = VehicleImpl.VehicleBuilder.newInstance("heavy").setLocationId("0,0").setType(heavyType).build(); +// +// +// TourStateUpdater tourStateCalculator = new TourStateUpdater(cost, new ExampleTransportCostFunction()); +// +// TourBuilder tourBuilder = new TourBuilder(); +// Service firstShipment = getService("10,0"); +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.scheduleDeliveryService(firstShipment); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// Tour tour = tourBuilder.build(); +// +// +// VehicleRoute route = new VehicleRoute(tour,new Driver(){},heavyVehicle); +// tourStateCalculator.updateTour(route); +// +// Collection vehicles = new ArrayList(); +// vehicles.add(lightVehicle); +// vehicles.add(heavyVehicle); +// VehicleFleetManager fleetManager = new VehicleFleetManagerImpl(vehicles); +// fleetManager.lock(heavyVehicle); +// +// FindCheaperVehicleAlgo findCheaperVehicle = new FindCheaperVehicleAlgo(fleetManager, tourStateCalculator); +// findCheaperVehicle.setWeightFixCosts(0.0); +// VehicleRoute newRoute = findCheaperVehicle.runAndGetVehicleRoute(route); +// +// assertThat(heavyVehicle, is(newRoute.getVehicle())); +// +// } +// +// @Test +// public void runCheaperVehicle_lightIsTheCheapest_doNotChangeVehicle(){ +// TourBuilder tourBuilder = new TourBuilder(); +// Service firstShipment = getService("10,0"); +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.scheduleDeliveryService(firstShipment); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// VehicleRoute route = new VehicleRoute(tourBuilder.build(),new Driver(){},lightVehicle); +// +// Collection vehicles = new ArrayList(); +// vehicles.add(lightVehicle); +// vehicles.add(heavyVehicle); +// VehicleFleetManager fleetManager = new VehicleFleetManagerImpl(vehicles); +// fleetManager.lock(heavyVehicle); +// +// TourStateUpdater tourStateCalculator = new TourStateUpdater(cost, new ExampleTransportCostFunction()); +// FindCheaperVehicleAlgo findCheaperVehicle = new FindCheaperVehicleAlgo(fleetManager, tourStateCalculator); +// VehicleRoute newRoute = findCheaperVehicle.runAndGetVehicleRoute(route); +// +// assertThat(lightVehicle, is(newRoute.getVehicle())); +// +// +// } +// +// @Test +// public void runCheaperVehicle_noAlterativeVehicle_doNotChangeVehicle(){ +// TourBuilder tourBuilder = new TourBuilder(); +// Service firstShipment = getService("10,0"); +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.scheduleDeliveryService(firstShipment); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// VehicleRoute route = new VehicleRoute(tourBuilder.build(),new Driver(){},heavyVehicle); +// +// Collection vehicles = new ArrayList(); +//// vehicles.add(lightVehicle); +// vehicles.add(heavyVehicle); +// VehicleFleetManager fleetManager = new VehicleFleetManagerImpl(vehicles); +// fleetManager.lock(heavyVehicle); +// +// TourStateUpdater tourStateCalculator = new TourStateUpdater(cost, new ExampleTransportCostFunction()); +// FindCheaperVehicleAlgo findCheaperVehicle = new FindCheaperVehicleAlgo(fleetManager, tourStateCalculator); +// VehicleRoute newRoute = findCheaperVehicle.runAndGetVehicleRoute(route); +// +// +// assertThat(heavyVehicle, is(newRoute.getVehicle())); +// +// } +// +// @Test +// public void runCheaperVehicle_noTour_throwException(){ +// TourBuilder tourBuilder = new TourBuilder(); +// Service firstShipment = getService("10,0"); +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.scheduleDeliveryService(firstShipment); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// VehicleRoute route = new VehicleRoute(null,null,heavyVehicle); +// +// Collection vehicles = new ArrayList(); +//// vehicles.add(lightVehicle); +// vehicles.add(heavyVehicle); +// VehicleFleetManager fleetManager = new VehicleFleetManagerImpl(vehicles); +// fleetManager.lock(heavyVehicle); +// +// TourStateUpdater tourStateCalculator = new TourStateUpdater(cost, new ExampleTransportCostFunction()); +// FindCheaperVehicleAlgo findCheaperVehicle = new FindCheaperVehicleAlgo(fleetManager, tourStateCalculator); +// VehicleRoute newRoute = findCheaperVehicle.runAndGetVehicleRoute(route); +// +// assertThat(heavyVehicle, is(newRoute.getVehicle())); +// } +// +// private Service getService(String to, double serviceTime) { +// Service s = Service.Builder.newInstance("s", 0).setLocationId(to).setServiceTime(serviceTime).setTimeWindow(TimeWindow.newInstance(0.0, 20.0)).build(); +// return s; +// } +// +// private Service getService(String to) { +// Service s = getService(to, 0.0); +// return s; +// } +// +// +// +// +// +//} diff --git a/jsprit-core/src/test/java/algorithms/GendreauPostOptTest.java b/jsprit-core/src/test/java/algorithms/GendreauPostOptTest.java new file mode 100644 index 00000000..87cc4820 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/GendreauPostOptTest.java @@ -0,0 +1,285 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.junit.Before; +import org.junit.Test; + +import util.Coordinate; +import util.ManhattanDistanceCalculator; +import util.RouteUtils; +import basics.Job; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.DriverImpl; +import basics.route.TimeWindow; +import basics.route.TourActivities; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + +public class GendreauPostOptTest { + + TourActivities tour; + + Vehicle heavyVehicle; + + Vehicle lightVehicle1; + + Vehicle lightVehicle2; + + VehicleRoutingTransportCosts cost; + + VehicleRoutingProblem vrp; + + Service job1; + + Service job2; + + Service job3; + + private RouteStates states; + + private List vehicles; + + private TourStateUpdater updater; + + private VehicleFleetManagerImpl fleetManager; + + private RouteAlgorithmImpl routeAlgorithm; + + @Before + public void setUp(){ + + cost = new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportTime(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + + String[] fromTokens = fromId.split(","); + String[] toTokens = toId.split(","); + double fromX = Double.parseDouble(fromTokens[0]); + double fromY = Double.parseDouble(fromTokens[1]); + + double toX = Double.parseDouble(toTokens[0]); + double toY = Double.parseDouble(toTokens[1]); + + double costPerDistanceUnit; + if(vehicle != null){ + costPerDistanceUnit = vehicle.getType().vehicleCostParams.perDistanceUnit; + } + else{ + costPerDistanceUnit = 1; + } + + return costPerDistanceUnit*ManhattanDistanceCalculator.calculateDistance(new Coordinate(fromX, fromY), new Coordinate(toX, toY)); + } + + @Override + public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + return 0; + } + }; + + VehicleType lightType = VehicleImpl.VehicleType.Builder.newInstance("light", 10).setFixedCost(10).setCostPerDistance(1.0).build(); + VehicleType heavyType = VehicleImpl.VehicleType.Builder.newInstance("heavy", 10).setFixedCost(30).setCostPerDistance(2.0).build(); + + lightVehicle1 = VehicleImpl.VehicleBuilder.newInstance("light").setLocationId("0,0").setType(lightType).build(); + lightVehicle2 = VehicleImpl.VehicleBuilder.newInstance("light2").setLocationId("0,0").setType(lightType).build(); + heavyVehicle = VehicleImpl.VehicleBuilder.newInstance("heavy").setLocationId("0,0").setType(heavyType).build(); + + + job1 = getService("10,0"); + job2 = getService("10,10"); + job3 = getService("0,10"); + + Collection jobs = new ArrayList(); + jobs.add(job1); + jobs.add(job2); + jobs.add(job3); + + vehicles = Arrays.asList(lightVehicle1,lightVehicle2, heavyVehicle); + +// Collection vehicles = Arrays.asList(lightVehicle1,lightVehicle2, heavyVehicle); + fleetManager = new VehicleFleetManagerImpl(vehicles); + states = new RouteStates(); + + ExampleActivityCostFunction activityCosts = new ExampleActivityCostFunction(); + + CalculatesServiceInsertion standardServiceInsertion = new CalculatesServiceInsertion(cost, activityCosts); + standardServiceInsertion.setActivityStates(states); + CalculatesServiceInsertionConsideringFixCost withFixCost = new CalculatesServiceInsertionConsideringFixCost(standardServiceInsertion, states); + withFixCost.setWeightOfFixCost(1.2); + + final JobInsertionCalculator vehicleTypeDepInsertionCost = new CalculatesVehTypeDepServiceInsertion(fleetManager, withFixCost); + updater = new TourStateUpdater(states, cost, activityCosts); + + + routeAlgorithm = RouteAlgorithmImpl.newInstance(vehicleTypeDepInsertionCost, updater); + routeAlgorithm.setActivityStates(states); + if(fleetManager != null){ + routeAlgorithm.getListeners().add(new RouteAlgorithm.VehicleSwitchedListener() { + + @Override + public void vehicleSwitched(Vehicle oldVehicle, Vehicle newVehicle) { + fleetManager.unlock(oldVehicle); + fleetManager.lock(newVehicle); + } + }); + } + + + } + + @Test + public void whenPostOpt_splitsTour_oneActiveTourBecomeTwoSeperateActiveTours(){ + Collection jobs = new ArrayList(); + jobs.add(job1); + jobs.add(job2); + + states.initialiseStateOfJobs(jobs); + vrp = VehicleRoutingProblem.Builder.newInstance().addAllJobs(jobs).addAllVehicles(vehicles).setRoutingCost(cost).build(); + + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(job1, true)); + tour.addActivity(states.getActivity(job2, true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,DriverImpl.noDriver(),heavyVehicle); + updater.updateRoute(route); + + fleetManager.lock(heavyVehicle); + + Collection routes = new ArrayList(); + routes.add(route); +// routes.add(new VehicleRoute(getEmptyTour(),getDriver(),getNoVehicle())); +// routes.add(new VehicleRoute(getEmptyTour(),getDriver(),getNoVehicle())); + + VehicleRoutingProblemSolution sol = new VehicleRoutingProblemSolution(routes, route.getCost()); + + assertEquals(110.0, sol.getCost(), 0.5); + + RuinRadial radialRuin = RuinRadial.newInstance(vrp, 0.2, new JobDistanceAvgCosts(vrp.getTransportCosts()), new JobRemoverImpl(), updater); + AbstractInsertionStrategy insertionStrategy = new BestInsertion(routeAlgorithm); + GendreauPostOpt postOpt = new GendreauPostOpt(vrp, radialRuin, insertionStrategy); + postOpt.setFleetManager(fleetManager); + VehicleRoutingProblemSolution newSolution = postOpt.runAndGetSolution(sol); + + assertEquals(2,RouteUtils.getNuOfActiveRoutes(newSolution.getRoutes())); + assertEquals(2,newSolution.getRoutes().size()); + assertEquals(80.0,newSolution.getCost(),0.5); + } + + @Test + public void whenPostOpt_optsRoutesWithMoreThanTwoJobs_oneRouteBecomesTwoRoutes(){ + Collection jobs = new ArrayList(); + jobs.add(job1); + jobs.add(job2); + jobs.add(job3); + + states.initialiseStateOfJobs(jobs); + vrp = VehicleRoutingProblem.Builder.newInstance().addAllJobs(jobs).addAllVehicles(vehicles).setRoutingCost(cost).build(); + + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(job1, true)); + tour.addActivity(states.getActivity(job2, true)); + tour.addActivity(states.getActivity(job3, true)); + + + VehicleRoute route = VehicleRoute.newInstance(tour,DriverImpl.noDriver(),heavyVehicle); + updater.updateRoute(route); + + fleetManager.lock(heavyVehicle); + + Collection routes = new ArrayList(); + routes.add(route); +// routes.add(new VehicleRoute(getEmptyTour(),getDriver(),getNoVehicle())); +// routes.add(new VehicleRoute(getEmptyTour(),getDriver(),getNoVehicle())); + + VehicleRoutingProblemSolution sol = new VehicleRoutingProblemSolution(routes, route.getCost()); + + assertEquals(110.0, sol.getCost(), 0.5); + + RuinRadial radialRuin = RuinRadial.newInstance(vrp, 0.2, new JobDistanceAvgCosts(vrp.getTransportCosts()), new JobRemoverImpl(), updater); + AbstractInsertionStrategy insertionStrategy = new BestInsertion(routeAlgorithm); + GendreauPostOpt postOpt = new GendreauPostOpt(vrp, radialRuin, insertionStrategy); + postOpt.setShareOfJobsToRuin(1.0); + postOpt.setNuOfIterations(1); + postOpt.setFleetManager(fleetManager); +// postOpt.setWithFix(withFixCost); + VehicleRoutingProblemSolution newSolution = postOpt.runAndGetSolution(sol); + + assertEquals(2,RouteUtils.getNuOfActiveRoutes(newSolution.getRoutes())); + assertEquals(2,newSolution.getRoutes().size()); + assertEquals(80.0,newSolution.getCost(),0.5); + } + + private Vehicle getNoVehicle() { + return new VehicleImpl.NoVehicle(); + } + + private Driver getDriver() { + return DriverImpl.noDriver(); + } + + private TourActivities getEmptyTour() { + return new TourActivities(); + } + + private Service getService(String to, double serviceTime) { + Service s = Service.Builder.newInstance(to, 0).setLocationId(to).setServiceTime(serviceTime).setTimeWindow(TimeWindow.newInstance(0.0, 20.0)).build(); + + return s; + } + + private Service getService(String to) { + Service s = getService(to, 0.0); + return s; + } + + + + +} diff --git a/jsprit-core/src/test/java/algorithms/TestAlgorithmReader.java b/jsprit-core/src/test/java/algorithms/TestAlgorithmReader.java new file mode 100644 index 00000000..f9288f40 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestAlgorithmReader.java @@ -0,0 +1,289 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashSet; +import java.util.Set; + +import org.apache.commons.configuration.ConfigurationException; +import org.apache.commons.configuration.XMLConfiguration; +import org.junit.Before; +import org.junit.Test; + +import algorithms.VehicleRoutingAlgorithms.ModKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.AcceptorKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.RuinStrategyKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.SelectorKey; +import algorithms.VehicleRoutingAlgorithms.TypedMap.StrategyModuleKey; +import algorithms.acceptors.AcceptNewIfBetterThanWorst; +import algorithms.acceptors.SolutionAcceptor; +import algorithms.selectors.SelectBest; +import algorithms.selectors.SolutionSelector; +import basics.Job; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.SearchStrategy; +import basics.algo.SearchStrategyModule; +import basics.algo.SearchStrategyModuleListener; +import basics.io.VrpXMLReader; +import basics.route.VehicleRoute; + +public class TestAlgorithmReader { + + XMLConfiguration config; + + VehicleRoutingProblem vrp; + + Collection solutions; + + @Before + public void doBefore() throws ConfigurationException{ + config = new XMLConfiguration("src/test/resources/testConfig.xml"); + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.Builder.newInstance(); + solutions = new ArrayList(); + new VrpXMLReader(vrpBuilder,solutions).read("src/test/resources/finiteVrpForReaderV2Test.xml"); + vrp = vrpBuilder.build(); + } + + @Test + public void testTypedMap(){ + algorithms.VehicleRoutingAlgorithms.TypedMap typedMap = new algorithms.VehicleRoutingAlgorithms.TypedMap(); + + String acceptorName = "acceptor"; + String acceptorId = "acceptorId"; + + ModKey key = new ModKey(acceptorName,acceptorId); + AcceptorKey accKey = new AcceptorKey(key); + + SolutionAcceptor acceptor = new AcceptNewIfBetterThanWorst(1); + + typedMap.put(accKey, acceptor); + + assertEquals(acceptor,typedMap.get(accKey)); + + } + + @Test + public void testTypedMap2(){ + algorithms.VehicleRoutingAlgorithms.TypedMap typedMap = new algorithms.VehicleRoutingAlgorithms.TypedMap(); + + String acceptorName = "acceptor"; + String acceptorId = "acceptorId"; + + String selectorName = "selector"; + String selectorId = "selectorId"; + + ModKey key = new ModKey(acceptorName,acceptorId); + AcceptorKey accKey = new AcceptorKey(key); + SolutionAcceptor acceptor = new AcceptNewIfBetterThanWorst(1); + + SelectorKey selKey = new SelectorKey(new ModKey(selectorName,selectorId)); + SolutionSelector selector = new SelectBest(); + + typedMap.put(accKey, acceptor); + typedMap.put(selKey, selector); + + assertEquals(acceptor,typedMap.get(accKey)); + assertEquals(selector, typedMap.get(selKey)); + } + + @Test + public void testTypedMap3(){ + algorithms.VehicleRoutingAlgorithms.TypedMap typedMap = new algorithms.VehicleRoutingAlgorithms.TypedMap(); + + String acceptorName = "acceptor"; + String acceptorId = "acceptorId"; + + String acceptorName2 = "acceptor2"; + String acceptorId2 = "acceptorId2"; + + String selectorName = "selector"; + String selectorId = "selectorId"; + + ModKey key = new ModKey(acceptorName,acceptorId); + AcceptorKey accKey = new AcceptorKey(key); + SolutionAcceptor acceptor = new AcceptNewIfBetterThanWorst(1); + + SelectorKey selKey = new SelectorKey(new ModKey(selectorName,selectorId)); + SolutionSelector selector = new SelectBest(); + + AcceptorKey accKey2 = new AcceptorKey(new ModKey(acceptorName2,acceptorId2)); + SolutionAcceptor acceptor2 = new AcceptNewIfBetterThanWorst(1); + + typedMap.put(accKey, acceptor); + typedMap.put(selKey, selector); + typedMap.put(accKey2, acceptor2); + + assertEquals(acceptor,typedMap.get(accKey)); + assertEquals(selector, typedMap.get(selKey)); + assertEquals(acceptor2,typedMap.get(accKey2)); + } + + @Test + public void testTypedMap4(){ + algorithms.VehicleRoutingAlgorithms.TypedMap typedMap = new algorithms.VehicleRoutingAlgorithms.TypedMap(); + + String acceptorName = "acceptor"; + String acceptorId = "acceptorId"; + + String moduleName = "acceptor"; + String moduleId = "acceptorId"; + + ModKey key = new ModKey(acceptorName,acceptorId); + RuinStrategyKey accKey = new RuinStrategyKey(key); + RuinStrategy acceptor = new RuinStrategy(){ + + @Override + public Collection ruin(Collection vehicleRoutes) { + // TODO Auto-generated method stub + return null; + } + + @Override + public Collection ruin(Collection vehicleRoutes, + Job targetJob, int nOfJobs2BeRemoved) { + // TODO Auto-generated method stub + return null; + } + + }; + + StrategyModuleKey moduleKey = new StrategyModuleKey(key); + SearchStrategyModule stratModule = new SearchStrategyModule() { + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + return null; + } + + @Override + public String getName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void addModuleListener( + SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } + };;; + + typedMap.put(accKey, acceptor); + typedMap.put(moduleKey, stratModule); + typedMap.put(moduleKey, stratModule); + + assertEquals(acceptor,typedMap.get(accKey)); + assertEquals(stratModule, typedMap.get(moduleKey)); + + } + + + + @Test + public void initialiseConstructionAlgoCorrectly(){ + VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + assertTrue(true); + } + + @Test + public void whenCreatingAlgorithm_nOfStrategiesIsCorrect(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + assertEquals(3, algo.getSearchStrategyManager().getStrategies().size()); + } + + @Test + public void whenCreatingAlgorithm_nOfIterationsIsReadCorrectly(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + assertEquals(10, algo.getNuOfIterations()); + } + + @Test + public void whenCreatingAlgorithm_nOfStrategyModulesIsCorrect(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + int nOfModules = 0; + for(SearchStrategy strat : algo.getSearchStrategyManager().getStrategies()){ + nOfModules += strat.getSearchStrategyModules().size(); + } + assertEquals(6, nOfModules); + } + + @Test + public void whenCreatingAlgorithm_nOfUniqueInstancesOfInsertionModulesIsCorrect(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + int nOfBestInsertions = 0; + Set uniqueStrategies = new HashSet(); + for(SearchStrategy strat : algo.getSearchStrategyManager().getStrategies()){ + for(SearchStrategyModule module : strat.getSearchStrategyModules()){ + if(module.getName().equals("bestInsertion")){ + nOfBestInsertions++; + uniqueStrategies.add(module); + } + } + + } + assertEquals(3, nOfBestInsertions); + assertEquals(2, uniqueStrategies.size()); + } + + @Test + public void whenCreatingAlgorithm_nOfUniqueInstancesOfRuinModulesIsCorrect(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, config); + int nOfRuinModules = 0; + Set uniqueStrategies = new HashSet(); + for(SearchStrategy strat : algo.getSearchStrategyManager().getStrategies()){ + for(SearchStrategyModule module : strat.getSearchStrategyModules()){ + if(module.getName().endsWith("Ruin")){ + nOfRuinModules++; + uniqueStrategies.add(module); + } + } + + } + assertEquals(3, nOfRuinModules); + assertEquals(2, uniqueStrategies.size()); + } + + @Test + public void whenCreatingAlgorithm_regretInsertionIsReadCorrectly(){ + VehicleRoutingAlgorithm algo = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/configWithRegretInsertion.xml"); + int nOfModules = 0; + for(SearchStrategy strat : algo.getSearchStrategyManager().getStrategies()){ + for(SearchStrategyModule module : strat.getSearchStrategyModules()){ + if(module.getName().contains("ruin_and_recreate")){ + nOfModules++; + } + } + + } + assertEquals(3, nOfModules); + + } + + +} diff --git a/jsprit-core/src/test/java/algorithms/TestAuxilliaryCostCalculatorWithServices.java b/jsprit-core/src/test/java/algorithms/TestAuxilliaryCostCalculatorWithServices.java new file mode 100644 index 00000000..e398882f --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestAuxilliaryCostCalculatorWithServices.java @@ -0,0 +1,218 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +//package algorithms; +// +//import java.util.ArrayList; +//import java.util.Collection; +//import java.util.List; +// +//import junit.framework.TestCase; +// +//import org.junit.Test; +// +//import util.EuclideanDistanceCalculator; +//import basics.Coordinate; +//import basics.Driver; +//import basics.Job; +//import basics.Service; +//import basics.TimeWindow; +//import basics.Tour; +//import basics.TourActivity; +//import basics.TourBuilder; +//import basics.Vehicle; +//import basics.VehicleRoutingTransportCosts; + +// +// +//public class TestAuxilliaryCostCalculatorWithServices extends TestCase{ +// +// AuxilliaryCostCalculator costCalc; +// +// Tour tour; +// +// public void setUp(){ +// +// VehicleRoutingTransportCosts cost = new VehicleRoutingTransportCosts() { +// +// @Override +// public double getBackwardTransportTime(String fromId, String toId, +// double arrivalTime, Driver driver, Vehicle vehicle) { +// // TODO Auto-generated method stub +// return 0; +// } +// +// @Override +// public double getBackwardTransportCost(String fromId, String toId, +// double arrivalTime, Driver driver, Vehicle vehicle) { +// // TODO Auto-generated method stub +// return 0; +// } +// +// @Override +// public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// String[] fromTokens = fromId.split(","); +// String[] toTokens = toId.split(","); +// double fromX = Double.parseDouble(fromTokens[0]); +// double fromY = Double.parseDouble(fromTokens[1]); +// +// double toX = Double.parseDouble(toTokens[0]); +// double toY = Double.parseDouble(toTokens[1]); +// +// return EuclideanDistanceCalculator.calculateDistance(new Coordinate(fromX, fromY), new Coordinate(toX, toY)); +// } +// +// @Override +// public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// +// return 0; +// } +// }; +// +// costCalc = AuxilliaryCostCalculator.newInstance(cost, new ExampleTransportCostFunction()); +// +// Service firstService = Service.Builder.newInstance("1", 0).setLocationId("10,0").setTimeWindow(TimeWindow.newInstance(0, 20)).build(); +// Service secondService = Service.Builder.newInstance("2", 0).setLocationId("0,10").setTimeWindow(TimeWindow.newInstance(0, 20)).build(); +// +// Collection services = new ArrayList(); +// services.add(firstService); +// services.add(secondService); +// +// ActivityStates states = new ActivityStates(); +// states.initialiseStateOfJobs(services); +// +// TourBuilder tourBuilder = new TourBuilder(); +// +// tourBuilder.scheduleStart("0,0", 0.0, Double.MAX_VALUE); +// tourBuilder.addActivity(states.getActivity(firstService,true)); +// tourBuilder.addActivity(states.getActivity(secondService,true)); +// tourBuilder.scheduleEnd("0,0", 0.0, Double.MAX_VALUE); +// +// tour = tourBuilder.build(); +// costCalc.setActivityStates(states); +// +// } +// +//// @Test +//// public void testGetPath(){ +//// List path = AuxilliaryCostCalculator.getPath(tour,tour.getStart(), tour.getActivities().get(1)); +//// assertEquals(3,path.size()); +//// } +//// +//// @Test +//// public void testGetPath_withEnd(){ +//// List path = AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(0), tour.getEnd()); +//// assertEquals(3,path.size()); +//// } +// +// +//// public void testCalcTourCost(){ +//// List path = AuxilliaryCostCalculator.getPath(tour,tour.getStart(), tour.getActivities().get(1)); +//// assertEquals(0.0, costCalc.costOfPath(path,0.0,null,null)); +//// } +// +//// public void testCalcTourCost2(){ +//// assertEquals(10.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(0), tour.getActivities().get(2)),0.0,null,null)); +//// } +//// +//// public void testCalcTourCost3(){ +//// assertEquals(20.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(2), tour.getActivities().get(6)),0.0,null,null)); +//// } +//// +//// public void testCalcTourCost4(){ +//// assertEquals(30.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(0), tour.getActivities().get(6)),0.0,null,null)); +//// } +//// +//// public void testCalcTourCost5(){ +//// assertEquals(40.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(1), tour.getActivities().get(7)),0.0,null,null)); +//// } +// +//// public void testCalcTourCost6(){ +//// assertEquals(0.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(1), tour.getActivities().get(1)),0.0,null,null)); +//// } +//// +//// public void testCalcTourCost7(){ +//// try{ +//// double c =costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(1), tour.getActivities().get(0)),0.0,null,null); +//// assertTrue(false); +//// } +//// catch(AssertionError e){ +//// assertTrue(true); +//// } +//// catch(IllegalArgumentException e){ +//// assertTrue(true); +//// } +//// } +//// +//// public void testCalcTourCost8(){ +//// try{ +//// Shipment s = getShipment("10,10","0,10"); +//// TourActivity pickup = new Pickup(s); +//// +//// double c = costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(0), pickup),0.0,null,null); +//// assertTrue(false); +//// } +//// catch(AssertionError e){ +//// assertTrue(true); +//// } +//// catch(IllegalArgumentException e){ +//// assertTrue(true); +//// } +//// } +//// +//// public void testBoundary1(){ +//// assertEquals(40.0, costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(1), tour.getActivities().get(tour.getActivities().size()-1)),0.0,null,null)); +//// } +//// +//// public void testBoundary2(){ +//// try{ +//// costCalc.costOfPath(AuxilliaryCostCalculator.getPath(tour,tour.getActivities().get(tour.getActivities().size()-1), tour.getActivities().get(0)),0.0,null,null); +//// assertTrue(false); +//// } +//// catch(AssertionError e){ +//// assertTrue(true); +//// } +//// catch(IllegalArgumentException e){ +//// assertTrue(true); +//// } +//// } +//// +////// public void testBoundary3(){ +////// assertEquals(40.0, costCalc.calculateCost(tour, tour.getActivities().getFirst(), tour.getActivities().getLast(), Double.MAX_VALUE, null, null)); +////// } +////// +////// public void testBoundary4(){ +////// try{ +////// costCalc.calculateCost(tour, tour.getActivities().getFirst(), tour.getActivities().getLast(), (-1)*Double.MAX_VALUE, null, null); +////// assertTrue(false); +////// } +////// catch(AssertionError e){ +////// assertTrue(true); +////// } +////// } +//// +//// +//// +//// private Shipment getShipment(String string, String string2) { +//// Shipment s = Shipment.Builder.newInstance("first", 0).setFromId(string).setToId(string2).setPickupTW(TimeWindow.newInstance(0.0, 20.0)).setDeliveryTW(TimeWindow.newInstance(0.0, 20.0)).build(); +//// return s; +//// } +//// +//} diff --git a/jsprit-core/src/test/java/algorithms/TestCalculatesActivityInsertion.java b/jsprit-core/src/test/java/algorithms/TestCalculatesActivityInsertion.java new file mode 100644 index 00000000..23d24618 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestCalculatesActivityInsertion.java @@ -0,0 +1,286 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.Arrays; +import java.util.List; + +import org.junit.Before; +import org.junit.Test; + +import algorithms.RouteStates.ActivityState; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; + + + +public class TestCalculatesActivityInsertion { + + VehicleRoutingTransportCosts costs; + + Vehicle newVehicle; + + private RouteStates states; + + private CalculatesActivityInsertionWithHardTimeWindows insertionCalculator; + + @Before + public void setup(){ + costs = mock(VehicleRoutingTransportCosts.class); + newVehicle = mock(Vehicle.class); + + when(costs.getTransportCost("depot", "1", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("depot", "2", 0.0, null, null)).thenReturn(20.0); + when(costs.getTransportCost("depot", "3", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("1", "2", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("1", "3", 0.0, null, null)).thenReturn(20.0); + when(costs.getTransportCost("2", "3", 0.0, null, null)).thenReturn(10.0); + + when(costs.getTransportCost("1", "depot", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("2", "depot", 0.0, null, null)).thenReturn(20.0); + when(costs.getTransportCost("3", "depot", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("2", "1", 0.0, null, null)).thenReturn(10.0); + when(costs.getTransportCost("3", "1", 0.0, null, null)).thenReturn(20.0); + when(costs.getTransportCost("3", "2", 0.0, null, null)).thenReturn(10.0); + + when(costs.getTransportCost("depot", "1", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("depot", "2", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("depot", "3", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "2", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "3", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("2", "3", 0.0, null, newVehicle)).thenReturn(20.0); + + when(costs.getTransportCost("1", "depot", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "depot", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "depot", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "1", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "1", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "2", 0.0, null, newVehicle)).thenReturn(20.0); + + states = new RouteStates(); + + insertionCalculator = new CalculatesActivityInsertionWithHardTimeWindows(states,costs,activityCosts()); + + } + + private ExampleActivityCostFunction activityCosts() { + return new ExampleActivityCostFunction(); + } + + public TourActivity getActivityMock(String id, double earliestOperationStart, double currCost){ + TourActivity act = mock(TourActivity.class); + when(act.getLocationId()).thenReturn(id); + states.getActivityStates().put(act, new ActivityState(act)); + states.getState(act).setEarliestOperationStart(earliestOperationStart); + states.getState(act).setCurrentCost(currCost); +// when(act.getEarliestOperationStartTime()).thenReturn(earliestOperationStart); +// when(act.getCurrentCost()).thenReturn(currCost); + return act; + } + + @Test + public void whenInsertingANewJob_itCalculatesMarginalCostChanges(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity prevAct = getActivityMock("1", 0.0, 10.0); + TourActivity nextAct = getActivityMock("3", 0.0, 30.0); + TourActivity act2insert = getActivityMock("2", 0.0, 0.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(prevAct); + vehicleRoute.getTourActivities().addActivity(nextAct); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,prevAct,nextAct,end); + when(tour.getActivities()).thenReturn(activities); +// when(states.getRouteState(vehicleRoute).getCosts()).thenReturn(40.0); + + double c = insertionCalculator.calculate(vehicleRoute, prevAct, nextAct, act2insert, null, null); + assertEquals(0.0,c,0.2); + } + + @Test + public void whenInsertingANewJob_itCalculatesMarginalCostChanges2(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 20.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(act2); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,act1,act2,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, act1, act2, act3, null, null); + assertEquals(20.0,c,0.2); + } + + @Test + public void whenInsertingANewJob_itCalculatesMarginalCostChanges3(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 0.0); + TourActivity end = getActivityMock("depot", 0.0, 20.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,act1,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, start, act1, act3, null, null); + assertEquals(20.0,c,0.2); + } + + @Test + public void whenInsertingANewJobWithANewVehicle_itCalculatesLocalMarginalCostChanges(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 20.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(act2); + vehicleRoute.getTourActivities().addActivity(end); + + + List activities = Arrays.asList(start,act1,act2,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, act1, act2, act3, null, newVehicle); + assertEquals(50.0,c,0.2); + } + + @Test + public void whenInsertingANewJobWithANewVehicle_itCalculatesLocalMarginalCostChangesAndAfterInsertionCostChanges(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 20.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(act2); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,act1,act2,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, act1, act2, act3, null, newVehicle); + assertEquals(50.0,c,0.2); + } + +//already on route-level +// @Test +// public void whenInsertingANewJobWithANewVehicle_itCalculatesTotalMarginalCostChanges(){ +// Tour tour = mock(Tour.class); +// TourActivity start = getActivityMock("depot", 0.0, 0.0); +// TourActivity act1 = getActivityMock("1", 0.0, 10.0); +// TourActivity act3 = getActivityMock("3", 0.0, 0.0); +// TourActivity act2 = getActivityMock("2", 0.0, 20.0); +// TourActivity end = getActivityMock("depot", 0.0, 40.0); +// +// List activities = Arrays.asList(start,act1,act2,end); +// when(tour.getActivities()).thenReturn(activities); +// +// double c = insertionCalculator.calculate(tour, act1, act2, act3, null, newVehicle); +// assertEquals(80.0,c,0.2); +// } + + @Test + public void whenInsertingANewJobWithANewVehicle_itCalculatesTotalMarginalCostChanges2(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 20.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(act2); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,act1,act2,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, act2, end, act3, null, newVehicle); + assertEquals(20.0,c,0.2); + } + + @Test + public void whenInsertingANewJobWithANewVehicle_itCalculatesTotalMarginalCostChanges3(){ + VehicleRoute vehicleRoute = VehicleRoute.emptyRoute(); + + TourActivities tour = mock(TourActivities.class); + TourActivity start = getActivityMock("depot", 0.0, 0.0); + TourActivity act1 = getActivityMock("1", 0.0, 10.0); + TourActivity act3 = getActivityMock("3", 0.0, 0.0); + TourActivity act2 = getActivityMock("2", 0.0, 20.0); + TourActivity end = getActivityMock("depot", 0.0, 40.0); + + vehicleRoute.getTourActivities().addActivity(start); + vehicleRoute.getTourActivities().addActivity(act1); + vehicleRoute.getTourActivities().addActivity(act2); + vehicleRoute.getTourActivities().addActivity(end); + + List activities = Arrays.asList(start,act1,act2,end); + when(tour.getActivities()).thenReturn(activities); + + double c = insertionCalculator.calculate(vehicleRoute, start, act1, act3, null, newVehicle); + assertEquals(50.0,c,0.2); + } + +} diff --git a/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertion.java b/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertion.java new file mode 100644 index 00000000..2f3ee965 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertion.java @@ -0,0 +1,261 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.ArrayList; +import java.util.Collection; + +import org.apache.log4j.Level; +import org.apache.log4j.Logger; +import org.junit.Before; +import org.junit.Test; + +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.DriverImpl; +import basics.route.TimeWindow; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; +import basics.route.DriverImpl.NoDriver; + + + +public class TestCalculatesServiceInsertion { + + CalculatesServiceInsertion serviceInsertion; + + VehicleRoutingTransportCosts costs; + + Vehicle vehicle; + + Vehicle newVehicle; + + private Service first; + + private Service second; + + private Service third; + + private RouteStates states; + + private TourStateUpdater tourStateUpdater; + + private NoDriver driver; + + @Before + public void setup(){ + Logger.getRootLogger().setLevel(Level.DEBUG); + + costs = mock(VehicleRoutingTransportCosts.class); + vehicle = mock(Vehicle.class); + when(vehicle.getCapacity()).thenReturn(1000); + when(vehicle.getLocationId()).thenReturn("depot"); + when(vehicle.getEarliestDeparture()).thenReturn(0.0); + when(vehicle.getLatestArrival()).thenReturn(100.0); + + newVehicle = mock(Vehicle.class); + when(newVehicle.getCapacity()).thenReturn(1000); + when(newVehicle.getLocationId()).thenReturn("depot"); + when(newVehicle.getEarliestDeparture()).thenReturn(0.0); + when(newVehicle.getLatestArrival()).thenReturn(100.0); + + driver = DriverImpl.noDriver(); + + when(costs.getTransportCost("depot", "1", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("depot", "2", 0.0, driver, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("depot", "3", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("1", "2", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("1", "3", 0.0, driver, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "3", 0.0, driver, vehicle)).thenReturn(10.0); + + when(costs.getTransportCost("1", "depot", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("2", "depot", 0.0, driver, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "depot", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("2", "1", 0.0, driver, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("3", "1", 0.0, driver, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "2", 0.0, driver, vehicle)).thenReturn(10.0); + + when(costs.getTransportCost("depot", "1", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("depot", "2", 0.0, driver, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("depot", "3", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "2", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "3", 0.0, driver, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("2", "3", 0.0, driver, newVehicle)).thenReturn(20.0); + + when(costs.getTransportCost("1", "depot", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "depot", 0.0, driver, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "depot", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "1", 0.0, driver, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "1", 0.0, driver, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "2", 0.0, driver, newVehicle)).thenReturn(20.0); + + when(costs.getTransportCost("depot", "1", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("depot", "2", 0.0, null, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("depot", "3", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("1", "2", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("1", "3", 0.0, null, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "3", 0.0, null, vehicle)).thenReturn(10.0); + + when(costs.getTransportCost("1", "depot", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("2", "depot", 0.0, null, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "depot", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("2", "1", 0.0, null, vehicle)).thenReturn(10.0); + when(costs.getTransportCost("3", "1", 0.0, null, vehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "2", 0.0, null, vehicle)).thenReturn(10.0); + + when(costs.getTransportCost("depot", "1", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("depot", "2", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("depot", "3", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "2", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("1", "3", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("2", "3", 0.0, null, newVehicle)).thenReturn(20.0); + + when(costs.getTransportCost("1", "depot", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "depot", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "depot", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("2", "1", 0.0, null, newVehicle)).thenReturn(20.0); + when(costs.getTransportCost("3", "1", 0.0, null, newVehicle)).thenReturn(40.0); + when(costs.getTransportCost("3", "2", 0.0, null, newVehicle)).thenReturn(20.0); + + + first = Service.Builder.newInstance("1", 0).setLocationId("1").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + second = Service.Builder.newInstance("3", 0).setLocationId("3").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + third = Service.Builder.newInstance("2", 0).setLocationId("2").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + Collection jobs = new ArrayList(); + jobs.add(first); + jobs.add(second); + jobs.add(third); + + states = new RouteStates(); + states.initialiseStateOfJobs(jobs); + + ExampleActivityCostFunction activityCosts = new ExampleActivityCostFunction(); + + serviceInsertion = new CalculatesServiceInsertion(costs, activityCosts); + serviceInsertion.setActivityStates(states); + + tourStateUpdater = new TourStateUpdater(states, costs, activityCosts); + + + + } + + public TourActivity getActivityMock(String id, double earliestOperationStart, double currCost){ + TourActivity act = mock(TourActivity.class); + when(act.getLocationId()).thenReturn(id); + return act; + } + + @Test + public void whenInsertingTheFirstJobInAnEmptyTourWithVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, first, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(20.0, iData.getInsertionCost(), 0.2); + assertEquals(0, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingTheSecondJobInAnNonEmptyTourWithVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first, true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, second, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(20.0, iData.getInsertionCost(), 0.2); + assertEquals(0, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingThirdJobWithVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(second,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, third, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(0.0, iData.getInsertionCost(), 0.2); + assertEquals(1, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingThirdJobWithNewVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(second,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, third, newVehicle, newVehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(20.0, iData.getInsertionCost(), 0.2); + assertEquals(1, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingASecondJobWithAVehicle_itCalculatesLocalMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(third,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, second, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(0.0, iData.getInsertionCost(), 0.2); + assertEquals(2, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingASecondJobWithANewVehicle_itCalculatesLocalMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(third,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); +// route.addActivity(states.getActivity(first,true)); +// route.addActivity(states.getActivity(third,true)); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, second, newVehicle, newVehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(20.0, iData.getInsertionCost(), 0.2); + assertEquals(2, iData.getDeliveryInsertionIndex()); + } + + + +} diff --git a/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertionOnRouteLevel.java b/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertionOnRouteLevel.java new file mode 100644 index 00000000..06bc449c --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestCalculatesServiceInsertionOnRouteLevel.java @@ -0,0 +1,276 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.ArrayList; +import java.util.Collection; + +import org.apache.log4j.Level; +import org.apache.log4j.Logger; +import org.junit.Before; +import org.junit.Test; + +import util.Coordinate; +import util.ManhattanDistanceCalculator; +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.DriverImpl; +import basics.route.TimeWindow; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleRoute; +import basics.route.DriverImpl.NoDriver; + + + +public class TestCalculatesServiceInsertionOnRouteLevel { + + CalculatesServiceInsertionOnRouteLevel serviceInsertion; + + VehicleRoutingTransportCosts costs; + + Vehicle vehicle; + + Vehicle newVehicle; + + private Service first; + + private Service second; + + private Service third; + + private RouteStates states; + + private TourStateUpdater tourStateUpdater; + + private NoDriver driver; + + @Before + public void setup(){ + Logger.getRootLogger().setLevel(Level.DEBUG); + + costs = mock(VehicleRoutingTransportCosts.class); + vehicle = mock(Vehicle.class); + when(vehicle.getCapacity()).thenReturn(1000); + when(vehicle.getLocationId()).thenReturn("0,0"); + when(vehicle.getEarliestDeparture()).thenReturn(0.0); + when(vehicle.getLatestArrival()).thenReturn(100.0); + + newVehicle = mock(Vehicle.class); + when(newVehicle.getCapacity()).thenReturn(1000); + when(newVehicle.getLocationId()).thenReturn("0,0"); + when(newVehicle.getEarliestDeparture()).thenReturn(0.0); + when(newVehicle.getLatestArrival()).thenReturn(100.0); + + driver = DriverImpl.noDriver(); + + costs = new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportTime(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle veh) { + String[] fromTokens = fromId.split(","); + String[] toTokens = toId.split(","); + double fromX = Double.parseDouble(fromTokens[0]); + double fromY = Double.parseDouble(fromTokens[1]); + + double toX = Double.parseDouble(toTokens[0]); + double toY = Double.parseDouble(toTokens[1]); + + double dist = ManhattanDistanceCalculator.calculateDistance(new Coordinate(fromX, fromY), new Coordinate(toX, toY)); + if(veh == vehicle){ + return dist; + } + else if(veh == newVehicle){ + return 2*dist; + } + throw new IllegalStateException(); + } + + @Override + public double getTransportTime(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + }; + + + first = Service.Builder.newInstance("1", 0).setLocationId("0,10").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + second = Service.Builder.newInstance("3", 0).setLocationId("10,0").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + third = Service.Builder.newInstance("2", 0).setLocationId("10,10").setTimeWindow(TimeWindow.newInstance(0.0, 100.0)).build(); + Collection jobs = new ArrayList(); + jobs.add(first); + jobs.add(second); + jobs.add(third); + + states = new RouteStates(); + states.initialiseStateOfJobs(jobs); + + ExampleActivityCostFunction activityCosts = new ExampleActivityCostFunction(); + serviceInsertion = new CalculatesServiceInsertionOnRouteLevel(costs,activityCosts); + serviceInsertion.setNuOfActsForwardLooking(4); + serviceInsertion.setActivityStates(states); + + tourStateUpdater = new TourStateUpdater(states, costs, activityCosts); + + + + } + + public TourActivity getActivityMock(String id, double earliestOperationStart, double currCost){ + TourActivity act = mock(TourActivity.class); + when(act.getLocationId()).thenReturn(id); + return act; + } + + @Test + public void whenInsertingTheFirstJobInAnEmptyTourWithVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, first, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(20.0, iData.getInsertionCost(), 0.2); + assertEquals(0, iData.getDeliveryInsertionIndex()); + } + +// @Test +// public void whenInsertingTheSecondJobInAnNonEmptyTourWithVehicle_itCalculatesMarginalCostChanges(){ +// TourActivities tour = new TourActivities(); +// tour.addActivity(states.getActivity(first, true)); +// +// VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); +// tourStateUpdater.updateRoute(route); +// +// InsertionData iData = serviceInsertion.calculate(route, second, vehicle, null, Double.MAX_VALUE); +// assertEquals(20.0, iData.getInsertionCost(), 0.2); +// assertEquals(1, iData.getDeliveryInsertionIndex()); +// } + +// @Test +// public void whenInsertingTheSecotndJobInAnNonEmptyTourWithNewVehicle_itCalculatesMarginalCostChanges(){ +// TourActivities tour = new TourActivities(); +// tour.addActivity(states.getActivity(first, true)); +// +// VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); +// tourStateUpdater.updateRoute(route); +// +// InsertionData iData = serviceInsertion.calculate(route, second, newVehicle, null, Double.MAX_VALUE); +// assertEquals(40.0, iData.getInsertionCost(), 0.2); +// assertEquals(1, iData.getDeliveryInsertionIndex()); +// } + + @Test + public void whenInsertingThirdJobWithVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(second,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, third, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(0.0, iData.getInsertionCost(), 0.2); + assertEquals(1, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingThirdJobWithNewVehicle_itCalculatesMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(second,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, third, newVehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(40.0, iData.getInsertionCost(), 0.2); + assertEquals(1, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingASecondJobWithAVehicle_itCalculatesLocalMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(third,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, second, vehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(0.0, iData.getInsertionCost(), 0.2); + assertEquals(2, iData.getDeliveryInsertionIndex()); + } + + @Test + public void whenInsertingASecondJobWithANewVehicle_itCalculatesLocalMarginalCostChanges(){ + TourActivities tour = new TourActivities(); + tour.addActivity(states.getActivity(first,true)); + tour.addActivity(states.getActivity(third,true)); + + VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); + tourStateUpdater.updateRoute(route); + + InsertionData iData = serviceInsertion.calculate(route, second, newVehicle, vehicle.getEarliestDeparture(), null, Double.MAX_VALUE); + assertEquals(40.0, iData.getInsertionCost(), 0.2); + assertEquals(2, iData.getDeliveryInsertionIndex()); + } + +// @Test +// public void whenInsertingFirstJobWithANewVehicle_itCalculatesLocalMarginalCostChanges(){ +// TourActivities tour = new TourActivities(); +// tour.addActivity(states.getActivity(third,true)); +// tour.addActivity(states.getActivity(second,true)); +// +// VehicleRoute route = VehicleRoute.newInstance(tour,driver,vehicle); +// tourStateUpdater.updateRoute(route); +// +// InsertionData iData = serviceInsertion.calculate(route, second, newVehicle, null, Double.MAX_VALUE); +// assertEquals(40.0, iData.getInsertionCost(), 0.2); +// assertEquals(2, iData.getDeliveryInsertionIndex()); +// } + + +} diff --git a/jsprit-core/src/test/java/algorithms/TestDepartureTimeOpt.java b/jsprit-core/src/test/java/algorithms/TestDepartureTimeOpt.java new file mode 100644 index 00000000..8a2092e4 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestDepartureTimeOpt.java @@ -0,0 +1,212 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.*; +import static org.mockito.Mockito.mock; + +import java.util.Collection; + +import org.junit.Test; + +import util.Coordinate; +import util.Solutions; +import basics.Service; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.costs.VehicleRoutingActivityCosts; +import basics.route.Driver; +import basics.route.TimeWindow; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; + +public class TestDepartureTimeOpt { + + @Test + public void whenSettingOneCustWithTWAnd_NO_DepTimeChoice_totalCostsShouldBe50(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + VehicleType type = mock(VehicleType.class); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfig.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(20.0+30.0,Solutions.getBest(solutions).getCost(),0.1); + + } + + @Test + public void whenSettingOneCustWithTWAnd_NO_DepTimeChoice_depTimeShouldBe0(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + VehicleType type = mock(VehicleType.class); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfig.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(0.0,Solutions.getBest(solutions).getRoutes().iterator().next().getStart().getEndTime(),0.1); + + } + + @Test + public void whenSettingOneCustWithTWAndDepTimeChoice_totalCostsShouldBe50(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfigWithDepartureTimeChoice.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(20.0,Solutions.getBest(solutions).getCost(),0.1); + + } + + @Test + public void whenSettingOneCustWithTWAndDepTimeChoice_depTimeShouldBe0(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfigWithDepartureTimeChoice.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(30.0,Solutions.getBest(solutions).getRoutes().iterator().next().getStart().getEndTime(),0.1); + + } + + @Test + public void whenSettingTwoCustWithTWAndDepTimeChoice_totalCostsShouldBe50(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + + Service service2 = Service.Builder.newInstance("s2", 0).setLocationId("servLoc2").setCoord(Coordinate.newInstance(0, 20)). + setTimeWindow(TimeWindow.newInstance(30, 40)).build(); + + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addService(service2).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfigWithDepartureTimeChoice.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(40.0,Solutions.getBest(solutions).getCost(),0.1); + + } + + @Test + public void whenSettingTwoCustWithTWAndDepTimeChoice_depTimeShouldBe10(){ + TimeWindow timeWindow = TimeWindow.newInstance(40, 45); + Service service = Service.Builder.newInstance("s", 0).setLocationId("servLoc").setCoord(Coordinate.newInstance(0, 10)).setTimeWindow(timeWindow).build(); + + Service service2 = Service.Builder.newInstance("s2", 0).setLocationId("servLoc2").setCoord(Coordinate.newInstance(0, 20)). + setTimeWindow(TimeWindow.newInstance(30, 40)).build(); + + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("vehLoc").setLocationCoord(Coordinate.newInstance(0, 0)) + .setType(VehicleType.Builder.newInstance("vType", 0).build()).build(); + + VehicleRoutingProblem vrp = VehicleRoutingProblem.Builder.newInstance().addService(service).addService(service2).addVehicle(vehicle).build(); + vrp.setActivityCosts(new VehicleRoutingActivityCosts(){ + + @Override + public double getActivityCost(TourActivity tourAct, double arrivalTime, Driver driver, Vehicle vehicle) { + double waiting = Math.max(0, tourAct.getTheoreticalEarliestOperationStartTime() - arrivalTime)*1; + double late = Math.max(0, arrivalTime - tourAct.getTheoreticalLatestOperationStartTime())*100; + return waiting + late; + } + + }); + + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.readAndCreateAlgorithm(vrp, "src/test/resources/algorithmConfigWithDepartureTimeChoice.xml"); + Collection solutions = vra.searchSolutions(); + + assertEquals(10.0,Solutions.getBest(solutions).getRoutes().iterator().next().getStart().getEndTime(),0.1); + + } + +} diff --git a/jsprit-core/src/test/java/algorithms/TestJobDistanceAvgCosts.java b/jsprit-core/src/test/java/algorithms/TestJobDistanceAvgCosts.java new file mode 100644 index 00000000..2c359319 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestJobDistanceAvgCosts.java @@ -0,0 +1,102 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import org.junit.Test; + +import basics.Service; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.Vehicle; + +public class TestJobDistanceAvgCosts { + + public static void main(String[] args) { + VehicleRoutingTransportCosts costs = new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportTime(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { + + return 0; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getTransportCost(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle) { + String vehicleId = vehicle.getId(); + return 0; + } + + @Override + public double getTransportTime(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + }; + JobDistanceAvgCosts c = new JobDistanceAvgCosts(costs); + c.calculateDistance(Service.Builder.newInstance("1", 1).setLocationId("foo").build(), Service.Builder.newInstance("2", 2).setLocationId("foo").build()); + } + + @Test(expected=NullPointerException.class) + public void whenVehicleAndDriverIsNull_And_CostsDoesNotProvideAMethodForThis_throwException(){ +// (expected=NullPointerException.class) + VehicleRoutingTransportCosts costs = new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportTime(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { + + return 0; + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + + @Override + public double getTransportCost(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle) { + String vehicleId = vehicle.getId(); + return 0; + } + + @Override + public double getTransportTime(String fromId, String toId, + double departureTime, Driver driver, Vehicle vehicle) { + // TODO Auto-generated method stub + return 0; + } + }; + JobDistanceAvgCosts c = new JobDistanceAvgCosts(costs); + c.calculateDistance(Service.Builder.newInstance("1", 1).setLocationId("loc").build(), Service.Builder.newInstance("2", 2).setLocationId("loc").build()); + } + +} diff --git a/jsprit-core/src/test/java/algorithms/TestRefs.java b/jsprit-core/src/test/java/algorithms/TestRefs.java new file mode 100644 index 00000000..471775b7 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestRefs.java @@ -0,0 +1,55 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.*; + +import java.util.ArrayList; +import java.util.List; + +import org.junit.Test; + +import basics.route.Start; + +public class TestRefs { + + @Test + public void testReferencs(){ + List starts = new ArrayList(); + starts.add(Start.newInstance("foo0", 0.0, 0.0)); + starts.add(Start.newInstance("foo1", 1.0, 1.0)); + + doSmth(starts); + + assertTrue(starts.get(0).getLocationId().startsWith("foo")); + assertTrue(starts.get(1).getLocationId().startsWith("foo")); + } + + private void doSmth(List starts) { + int count = 0; + for(Start s : starts){ + s = Start.newInstance("yo_"+count,0.0,0.0); + count++; + } + + } + +} diff --git a/jsprit-core/src/test/java/algorithms/TestTourStateUpdaterWithService.java b/jsprit-core/src/test/java/algorithms/TestTourStateUpdaterWithService.java new file mode 100644 index 00000000..bdcd3713 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestTourStateUpdaterWithService.java @@ -0,0 +1,246 @@ +/******************************************************************************* + * Copyright (C) 2011 Stefan Schroeder. + * eMail: stefan.schroeder@kit.edu + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + ******************************************************************************/ +package algorithms; + +import static org.junit.Assert.assertEquals; + +import java.util.ArrayList; +import java.util.Collection; + +import org.junit.Before; +import org.junit.Test; + +import util.Coordinate; +import util.ManhattanDistanceCalculator; +import basics.Job; +import basics.Service; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.DriverImpl; +import basics.route.TimeWindow; +import basics.route.TourActivities; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleRoute; + + +public class TestTourStateUpdaterWithService { + + TourActivities tour; + + Driver driver; + + Vehicle vehicle; + + TourActivities anotherTour; + + TourStateUpdater tdTourStatusProcessor; + + RouteStates states; + + private VehicleRoute vehicleRoute; + + @Before + public void setUp() { + + VehicleRoutingTransportCosts cost = new VehicleRoutingTransportCosts() { + + @Override + public double getBackwardTransportTime(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, arrivalTime, driver, vehicle); + } + + @Override + public double getBackwardTransportCost(String fromId, String toId, + double arrivalTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, arrivalTime, driver, vehicle); + } + + @Override + public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + String[] fromTokens = fromId.split(","); + String[] toTokens = toId.split(","); + double fromX = Double.parseDouble(fromTokens[0]); + double fromY = Double.parseDouble(fromTokens[1]); + + double toX = Double.parseDouble(toTokens[0]); + double toY = Double.parseDouble(toTokens[1]); + + return ManhattanDistanceCalculator.calculateDistance(new Coordinate(fromX, fromY), new Coordinate(toX, toY)); + } + + @Override + public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + return getTransportCost(fromId, toId, departureTime, driver, vehicle); + } + }; + + Service firstService = Service.Builder.newInstance("1", 5).setLocationId("10,0").setTimeWindow(TimeWindow.newInstance(0, 20)).build(); + Service secondService = Service.Builder.newInstance("2", 5).setLocationId("0,10").setTimeWindow(TimeWindow.newInstance(0, 50)).build(); + + Collection services = new ArrayList(); + services.add(firstService); + services.add(secondService); + + states = new RouteStates(); + states.initialiseStateOfJobs(services); + + VehicleType type = VehicleImpl.VehicleType.Builder.newInstance("test", 0).build(); + vehicle = VehicleImpl.VehicleBuilder.newInstance("testvehicle").setType(type).setLocationId("0,0") + .setEarliestStart(0.0).setLatestArrival(50.0).build(); + + tour = new TourActivities(); + tour.addActivity(states.getActivity(firstService,true)); + tour.addActivity(states.getActivity(secondService,true)); + + tdTourStatusProcessor = new TourStateUpdater(states, cost, new ExampleActivityCostFunction()); + + + vehicleRoute = VehicleRoute.newInstance(tour,DriverImpl.noDriver(),vehicle); + } + + @Test + public void testCalculatedCost() { + tdTourStatusProcessor.updateRoute(vehicleRoute); + assertEquals(40.0, states.getRouteState(vehicleRoute).getCosts(), 0.05); + assertEquals(10, states.getRouteState(vehicleRoute).getLoad()); + } + + @Test + public void testStatesOfAct0(){ + tdTourStatusProcessor.updateRoute(vehicleRoute); + assertEquals(0.0, vehicleRoute.getStart().getEndTime(),0.05); + assertEquals(vehicleRoute.getVehicle().getLocationId(), vehicleRoute.getStart().getLocationId()); + assertEquals(vehicleRoute.getVehicle().getEarliestDeparture(), vehicleRoute.getStart().getTheoreticalEarliestOperationStartTime(),0.05); + assertEquals(vehicleRoute.getVehicle().getLatestArrival(), vehicleRoute.getStart().getTheoreticalLatestOperationStartTime(),0.05); + + } + + @Test + public void testStatesOfAct1(){ + tdTourStatusProcessor.updateRoute(vehicleRoute); + assertEquals(10.0, states.getState(tour.getActivities().get(0)).getCurrentCost(),0.05); + assertEquals(5.0, states.getState(tour.getActivities().get(0)).getCurrentLoad(),0.05); + assertEquals(10.0, states.getState(tour.getActivities().get(0)).getEarliestOperationStart(),0.05); + assertEquals(20.0, states.getState(tour.getActivities().get(0)).getLatestOperationStart(),0.05); + } + + @Test + public void testStatesOfAct2(){ + tdTourStatusProcessor.updateRoute(vehicleRoute); + assertEquals(30.0, states.getState(tour.getActivities().get(1)).getCurrentCost(),0.05); + assertEquals(10.0, states.getState(tour.getActivities().get(1)).getCurrentLoad(),0.05); + assertEquals(30.0, states.getState(tour.getActivities().get(1)).getEarliestOperationStart(),0.05); + assertEquals(40.0, states.getState(tour.getActivities().get(1)).getLatestOperationStart(),0.05); + } + + @Test + public void testStatesOfAct3(){ + tdTourStatusProcessor.updateRoute(vehicleRoute); + assertEquals(40.0, states.getRouteState(vehicleRoute).getCosts(), 0.05); + assertEquals(40.0, vehicleRoute.getEnd().getEndTime(),0.05); + assertEquals(50.0, vehicleRoute.getEnd().getTheoreticalLatestOperationStartTime(),0.05); + } + +// public void testEarliestArrStart() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(0.0, tour.getActivities().get(0) +// .getEarliestOperationStartTime()); +// } +// +// public void testLatestArrStart() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(0.0, tour.getActivities().get(0) +// .getLatestOperationStartTime()); +// } +// +// public void testEarliestArrAtFirstPickup() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(10.0, tour.getActivities().get(1) +// .getEarliestOperationStartTime()); +// } +// +// public void testEarliestArrAtFirstPickupWithTDCost() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(10.0, tour.getActivities().get(1) +// .getEarliestOperationStartTime()); +// } +// +// public void testLatestArrAtFirstPickup() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(10.0, tour.getActivities().get(1) +// .getLatestOperationStartTime()); +// } +// +// public void testLatestArrAtFirstPickupWithTDCost() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(12.0, tour.getActivities().get(1) +// .getLatestOperationStartTime()); +// } +// +// public void testEarliestArrAtSecondPickup() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(30.0, tour.getActivities().get(2) +// .getEarliestOperationStartTime()); +// } +// +// public void testEarliestArrAtSecondPickupWithTDCosts() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(30.0, tour.getActivities().get(2) +// .getEarliestOperationStartTime()); +// } +// +// public void testLatestArrAtSecondPickup() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(30.0, tour.getActivities().get(2) +// .getLatestOperationStartTime()); +// } +// +// public void testLatestArrAtSecondPickupWithTDCosts() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(30.0, tour.getActivities().get(2) +// .getLatestOperationStartTime()); +// } +// +// public void testEarliestArrAtEnd() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(40.0, tour.getActivities().get(5) +// .getEarliestOperationStartTime()); +// } +// +// public void testEarliestArrAtEndWithTDCosts() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(35.0, tour.getActivities().get(5) +// .getEarliestOperationStartTime()); +// } +// +// public void testLatestArrAtEnd() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(Double.MAX_VALUE, tour.getActivities().get(5) +// .getLatestOperationStartTime()); +// } +// +// public void testLatestArrAtEndWithTDCosts() { +// tdTourStatusProcessor.calculate(tour, vehicle, driver); +// assertEquals(Double.MAX_VALUE, tour.getActivities().get(5) +// .getLatestOperationStartTime()); +// } + +} diff --git a/jsprit-core/src/test/java/algorithms/TestVehicleFleetManager.java b/jsprit-core/src/test/java/algorithms/TestVehicleFleetManager.java new file mode 100644 index 00000000..f3e2333d --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/TestVehicleFleetManager.java @@ -0,0 +1,106 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleBuilder; +import basics.route.VehicleImpl.VehicleType; +import basics.route.VehicleImpl.VehicleType.Builder; + +import algorithms.VehicleFleetManager; +import algorithms.VehicleFleetManagerImpl; +import algorithms.VehicleFleetManager.TypeKey; + +import junit.framework.TestCase; + +public class TestVehicleFleetManager extends TestCase{ + + VehicleFleetManager fleetManager; + + Vehicle v1; + + Vehicle v2; + + public void setUp(){ + List vehicles = new ArrayList(); + + v1 = VehicleImpl.VehicleBuilder.newInstance("standard").setLocationId("loc").setType(VehicleImpl.VehicleType.Builder.newInstance("standard", 0).build()).build(); + v2 = VehicleImpl.VehicleBuilder.newInstance("foo").setLocationId("fooLoc").setType(VehicleImpl.VehicleType.Builder.newInstance("foo", 0).build()).build(); + + vehicles.add(v1); + vehicles.add(v2); + fleetManager = new VehicleFleetManagerImpl(vehicles); + } + + public void testGetTypes(){ + Collection types = fleetManager.getAvailableVehicleTypes(); + assertEquals(2, types.size()); + } + + public void testGetVehicle(){ + TypeKey typeKey = new TypeKey(v1.getType(),v1.getLocationId()); + Vehicle v = fleetManager.getEmptyVehicle(typeKey); + assertEquals(v.getId(), v1.getId()); + } + + public void testLock(){ + fleetManager.lock(v1); + Collection types = fleetManager.getAvailableVehicleTypes(); + assertEquals(1, types.size()); + } + + public void testLockTwice(){ + fleetManager.lock(v1); + Collection types = fleetManager.getAvailableVehicleTypes(); + assertEquals(1, types.size()); + try{ + fleetManager.lock(v1); + Collection types_ = fleetManager.getAvailableVehicleTypes(); + assertFalse(true); + } + catch(IllegalStateException e){ + assertTrue(true); + } + } + + public void testGetTypesWithout(){ + TypeKey typeKey = new TypeKey(v1.getType(),v1.getLocationId()); + Collection types = fleetManager.getAvailableVehicleTypes(typeKey); + + assertEquals(new TypeKey(v2.getType(),v2.getLocationId()), types.iterator().next()); + assertEquals(1, types.size()); + } + + public void testUnlock(){ + fleetManager.lock(v1); + Collection types = fleetManager.getAvailableVehicleTypes(); + assertEquals(1, types.size()); + fleetManager.unlock(v1); + Collection types_ = fleetManager.getAvailableVehicleTypes(); + assertEquals(2, types_.size()); + } + +} diff --git a/jsprit-core/src/test/java/algorithms/acceptors/AcceptNewRemoveWorstTest.java b/jsprit-core/src/test/java/algorithms/acceptors/AcceptNewRemoveWorstTest.java new file mode 100644 index 00000000..3d6be877 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/acceptors/AcceptNewRemoveWorstTest.java @@ -0,0 +1,62 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.acceptors; + +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertThat; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.ArrayList; +import java.util.List; + +import org.junit.Test; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + + +public class AcceptNewRemoveWorstTest { + + @Test + public void whenHavingNewSolAndLimitedMemory_removeWorstAndAddNew(){ + + VehicleRoutingProblem vrp = mock(VehicleRoutingProblem.class); + VehicleRoutingProblemSolution sol1 = mock(VehicleRoutingProblemSolution.class); + VehicleRoutingProblemSolution sol2 = mock(VehicleRoutingProblemSolution.class); + when(sol1.getCost()).thenReturn(1.0); + when(sol2.getCost()).thenReturn(2.0); + + List solList = new ArrayList(); + solList.add(sol1); + solList.add(sol2); + + VehicleRoutingProblemSolution sol3 = mock(VehicleRoutingProblemSolution.class); + + new AcceptNewIfBetterThanWorst(2).acceptSolution(solList, sol3); + + assertEquals(2,solList.size()); + assertThat(sol3,is(solList.get(1))); + } + +} diff --git a/jsprit-core/src/test/java/algorithms/selectors/SelectBestTest.java b/jsprit-core/src/test/java/algorithms/selectors/SelectBestTest.java new file mode 100644 index 00000000..e9877087 --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/selectors/SelectBestTest.java @@ -0,0 +1,61 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.selectors; + +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertThat; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.Arrays; +import java.util.Collections; + +import org.junit.Test; + +import basics.VehicleRoutingProblemSolution; + + + +public class SelectBestTest { + + @Test + public void whenHaving2Solutions_selectBest(){ + VehicleRoutingProblemSolution sol1 = mock(VehicleRoutingProblemSolution.class); + VehicleRoutingProblemSolution sol2 = mock(VehicleRoutingProblemSolution.class); + when(sol1.getCost()).thenReturn(1.0); + when(sol2.getCost()).thenReturn(2.0); + assertThat(new SelectBest().selectSolution(Arrays.asList(sol1,sol2)), is(sol1)); + } + + @Test + public void whenHavingOnly1Solutions_selectThisOne(){ + VehicleRoutingProblemSolution sol1 = mock(VehicleRoutingProblemSolution.class); + when(sol1.getCost()).thenReturn(1.0); + assertThat(new SelectBest().selectSolution(Arrays.asList(sol1)), is(sol1)); + } + + @Test + public void whenHavingNoSolutions_returnNull(){ + assertNull(new SelectBest().selectSolution(Collections.EMPTY_LIST)); + } + +} diff --git a/jsprit-core/src/test/java/algorithms/selectors/SelectRandomlyTest.java b/jsprit-core/src/test/java/algorithms/selectors/SelectRandomlyTest.java new file mode 100644 index 00000000..c8989a4d --- /dev/null +++ b/jsprit-core/src/test/java/algorithms/selectors/SelectRandomlyTest.java @@ -0,0 +1,87 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package algorithms.selectors; + +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertThat; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.Arrays; +import java.util.Collections; +import java.util.Random; + +import org.junit.Test; + +import algorithms.selectors.SelectRandomly; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; + + +public class SelectRandomlyTest { + + @Test + public void whenHaving2Solutions_selectSecond(){ + VehicleRoutingProblemSolution sol1 = mock(VehicleRoutingProblemSolution.class); + VehicleRoutingProblemSolution sol2 = mock(VehicleRoutingProblemSolution.class); + + when(sol1.getCost()).thenReturn(1.0); + when(sol2.getCost()).thenReturn(2.0); + + Random random = mock(Random.class); + when(random.nextInt(2)).thenReturn(1); + + SelectRandomly selectRandomly = new SelectRandomly(); + selectRandomly.setRandom(random); + + assertThat(selectRandomly.selectSolution(Arrays.asList(sol1,sol2)), is(sol2)); + } + + @Test + public void whenHaving2Solutions_selectFirst(){ + + VehicleRoutingProblemSolution sol1 = mock(VehicleRoutingProblemSolution.class); + VehicleRoutingProblemSolution sol2 = mock(VehicleRoutingProblemSolution.class); + + when(sol1.getCost()).thenReturn(1.0); + when(sol2.getCost()).thenReturn(2.0); + + Random random = mock(Random.class); + when(random.nextInt(2)).thenReturn(0); + + SelectRandomly selectRandomly = new SelectRandomly(); + selectRandomly.setRandom(random); + + assertThat(selectRandomly.selectSolution(Arrays.asList(sol1,sol2)), is(sol1)); + } + + @Test + public void whenHavingNoSolutions_returnNull(){ + Random random = mock(Random.class); + when(random.nextInt(2)).thenReturn(0); + + SelectRandomly selectRandomly = new SelectRandomly(); + selectRandomly.setRandom(random); + + assertNull(selectRandomly.selectSolution(Collections.EMPTY_LIST)); + } +} diff --git a/jsprit-core/src/test/java/allsuites/AllTests.java b/jsprit-core/src/test/java/allsuites/AllTests.java new file mode 100644 index 00000000..143c2e4e --- /dev/null +++ b/jsprit-core/src/test/java/allsuites/AllTests.java @@ -0,0 +1,39 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package allsuites; + +import org.junit.runner.RunWith; +import org.junit.runners.Suite; + +import algorithms.AlgorithmsSuite; +import basics.BasicsSuite; + + + +@RunWith(Suite.class) +@Suite.SuiteClasses({ + AlgorithmsSuite.class, + BasicsSuite.class +}) +public class AllTests {} + + + diff --git a/jsprit-core/src/test/java/basics/BasicsSuite.java b/jsprit-core/src/test/java/basics/BasicsSuite.java new file mode 100644 index 00000000..e56befe8 --- /dev/null +++ b/jsprit-core/src/test/java/basics/BasicsSuite.java @@ -0,0 +1,54 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import org.junit.runner.RunWith; +import org.junit.runners.Suite; + +import algorithms.TestVehicleFleetManager; +import basics.algo.SearchStrategyManagerTest; +import basics.algo.SearchStrategyTest; +import basics.io.VrpReaderV2Test; +import basics.io.VrpWriterV2Test; +import basics.io.VrpWriterV3Test; +import basics.route.ServiceActTest; +import basics.route.TestTour; +import basics.route.TestVehicleRoute; + + + + +@RunWith(Suite.class) +@Suite.SuiteClasses({ + SearchStrategyManagerTest.class, + SearchStrategyTest.class, + TestTour.class, + TestVehicleFleetManager.class, + TestVehicleRoute.class, + ServiceActTest.class, + ServiceTest.class, + VehicleRoutingProblemBuilderTest.class, + VrpReaderV2Test.class, + VrpWriterV2Test.class, + VrpWriterV3Test.class + +}) +public class BasicsSuite {} diff --git a/jsprit-core/src/test/java/basics/ServiceTest.java b/jsprit-core/src/test/java/basics/ServiceTest.java new file mode 100644 index 00000000..d198ee1e --- /dev/null +++ b/jsprit-core/src/test/java/basics/ServiceTest.java @@ -0,0 +1,60 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import static org.junit.Assert.assertTrue; + +import java.util.HashSet; +import java.util.Set; + +import org.junit.Test; + + +public class ServiceTest { + + @Test + public void whenTwoServicesHaveTheSameId_theyShouldBeEqual(){ + Service one = Service.Builder.newInstance("service", 10).setLocationId("foo").build(); + Service two = Service.Builder.newInstance("service", 10).setLocationId("fo").build(); + + assertTrue(one != two); + } + + @Test + public void whenTwoServicesHaveTheSameId_theyShouldBeEqual2(){ + Service one = Service.Builder.newInstance("service", 10).setLocationId("foo").build(); + Service two = Service.Builder.newInstance("service", 10).setLocationId("fo").build(); + + assertTrue(one.equals(two)); + } + + @Test + public void noName(){ + Set serviceSet = new HashSet(); + Service one = Service.Builder.newInstance("service", 10).setLocationId("foo").build(); + Service two = Service.Builder.newInstance("service", 10).setLocationId("fo").build(); + serviceSet.add(one); +// assertTrue(serviceSet.contains(two)); + serviceSet.remove(two); + assertTrue(serviceSet.isEmpty()); + + } +} diff --git a/jsprit-core/src/test/java/basics/VehicleRoutingProblemBuilderTest.java b/jsprit-core/src/test/java/basics/VehicleRoutingProblemBuilderTest.java new file mode 100644 index 00000000..46d83863 --- /dev/null +++ b/jsprit-core/src/test/java/basics/VehicleRoutingProblemBuilderTest.java @@ -0,0 +1,72 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics; + +import static org.junit.Assert.assertEquals; + +import org.junit.Test; + +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; + +public class VehicleRoutingProblemBuilderTest { + + @Test + public void buildsProblemWithInfiniteVehiclesCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetSize(FleetSize.INFINITE); +// Depot depot = new Depot("depot1", Coordinate.newInstance(0, 0)); +// builder.assignVehicleType(depot, VehicleType.Builder.newInstance("t1", 20).build()); +// builder.assignVehicleType(depot, VehicleType.Builder.newInstance("t2", 200).build()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.INFINITE,vrp.getFleetSize()); + + } + + @Test + public void buildsProblemWithFiniteVehiclesCorrectly_checkVehiclesAndTypesSizes(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetSize(FleetSize.FINITE); + + VehicleType type1 = VehicleType.Builder.newInstance("t1", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("t2", 200).build(); + + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("yo").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("yo").setType(type1).build(); + Vehicle v3 = VehicleImpl.VehicleBuilder.newInstance("v3").setLocationId("yo").setType(type2).build(); + Vehicle v4 = VehicleImpl.VehicleBuilder.newInstance("v4").setLocationId("yo").setType(type2).build(); + + builder.addVehicle(v1); + builder.addVehicle(v2); + builder.addVehicle(v3); + builder.addVehicle(v4); + + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.FINITE,vrp.getFleetSize()); + assertEquals(4,vrp.getVehicles().size()); + assertEquals(2,vrp.getTypes().size()); + + } + + +} diff --git a/jsprit-core/src/test/java/basics/algo/SearchStrategyManagerTest.java b/jsprit-core/src/test/java/basics/algo/SearchStrategyManagerTest.java new file mode 100644 index 00000000..067494a9 --- /dev/null +++ b/jsprit-core/src/test/java/basics/algo/SearchStrategyManagerTest.java @@ -0,0 +1,145 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import static org.hamcrest.CoreMatchers.is; +import static org.junit.Assert.assertThat; +import static org.junit.Assert.assertTrue; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.stub; +import static org.mockito.Mockito.when; + +import java.util.Random; + +import org.junit.Test; + +import basics.algo.SearchStrategy; +import basics.algo.SearchStrategyManager; + + + +public class SearchStrategyManagerTest { + + @Test + public void StrategyManagerInAction_addingStrategy_IsSuccessful(){ + SearchStrategyManager manager = new SearchStrategyManager(); + SearchStrategy strat1 = mock(SearchStrategy.class); + SearchStrategy strat2 = mock(SearchStrategy.class); + manager.addStrategy(strat1, 0.5); + manager.addStrategy(strat2, 0.5); + assertTrue(true); + } + + @Test(expected=IllegalStateException.class) + public void StrategyManagerInAction_strategyIsNull_throwsException(){ + SearchStrategyManager manager = new SearchStrategyManager(); + manager.addStrategy(null, 1.0); + assertTrue(false); + } + + @Test(expected=IllegalStateException.class) + public void StrategyManagerInAction_probabilityIsHigherThanOne_throwsException(){ + SearchStrategyManager manager = new SearchStrategyManager(); + SearchStrategy strat = mock(SearchStrategy.class); + manager.addStrategy(strat, 1.5); + assertTrue(false); + } + + @Test(expected=IllegalStateException.class) + public void StrategyManagerInAction_probabilityIsLowerThanZero_throwsException(){ + SearchStrategyManager manager = new SearchStrategyManager(); + SearchStrategy strat = mock(SearchStrategy.class); + manager.addStrategy(strat, -1.0); + assertTrue(false); + } + + @Test(expected = IllegalStateException.class) + public void StrategyManagerInAction_addingSeveralStratsLeadsToAProbHigherThanOne_throwsException(){ + SearchStrategyManager manager = new SearchStrategyManager(); + SearchStrategy mockedStrat1 = mock(SearchStrategy.class); + SearchStrategy mockedStrat2 = mock(SearchStrategy.class); + + manager.addStrategy(mockedStrat1, 0.5); + manager.addStrategy(mockedStrat2, 0.6); + } + + @Test + public void whenRandomDices_0point1_returnsStrategy1(){ + SearchStrategyManager managerUnderTest = new SearchStrategyManager(); + SearchStrategy mockedStrategy1 = mock(SearchStrategy.class); + SearchStrategy mockedStrategy2 = mock(SearchStrategy.class); + managerUnderTest.addStrategy(mockedStrategy1, 0.2); + managerUnderTest.addStrategy(mockedStrategy2, 0.8); + + Random mockedRandom = mock(Random.class); + managerUnderTest.setRandom(mockedRandom); + stub(mockedRandom.nextDouble()).toReturn(0.1); + + assertThat(managerUnderTest.getRandomStrategy(), is(mockedStrategy1)); + + } + + @Test + public void whenRandomDices_0point5_returnsStrategy2(){ + SearchStrategyManager managerUnderTest = new SearchStrategyManager(); + SearchStrategy mockedStrategy1 = mock(SearchStrategy.class); + SearchStrategy mockedStrategy2 = mock(SearchStrategy.class); + managerUnderTest.addStrategy(mockedStrategy1, 0.2); + managerUnderTest.addStrategy(mockedStrategy2, 0.8); + + Random mockedRandom = mock(Random.class); + managerUnderTest.setRandom(mockedRandom); + when(mockedRandom.nextDouble()).thenReturn(0.5); + + assertThat(managerUnderTest.getRandomStrategy(), is(mockedStrategy2)); + + } + + @Test + public void whenRandomDices_0point0_returnsStrategy1(){ + SearchStrategyManager managerUnderTest = new SearchStrategyManager(); + SearchStrategy mockedStrategy1 = mock(SearchStrategy.class); + SearchStrategy mockedStrategy2 = mock(SearchStrategy.class); + managerUnderTest.addStrategy(mockedStrategy1, 0.2); + managerUnderTest.addStrategy(mockedStrategy2, 0.8); + + Random mockedRandom = mock(Random.class); + managerUnderTest.setRandom(mockedRandom); + when(mockedRandom.nextDouble()).thenReturn(0.0); + + assertThat(managerUnderTest.getRandomStrategy(), is(mockedStrategy1)); + + } + + @Test(expected=IllegalStateException.class) + public void whenRandomIsNull_throwException(){ + SearchStrategyManager managerUnderTest = new SearchStrategyManager(); + SearchStrategy mockedStrategy1 = mock(SearchStrategy.class); + SearchStrategy mockedStrategy2 = mock(SearchStrategy.class); + managerUnderTest.addStrategy(mockedStrategy1, 0.2); + managerUnderTest.addStrategy(mockedStrategy2, 0.8); + + Random mockedRandom = null; + managerUnderTest.setRandom(mockedRandom); + managerUnderTest.getRandomStrategy(); + + } +} diff --git a/jsprit-core/src/test/java/basics/algo/SearchStrategyTest.java b/jsprit-core/src/test/java/basics/algo/SearchStrategyTest.java new file mode 100644 index 00000000..183f245b --- /dev/null +++ b/jsprit-core/src/test/java/basics/algo/SearchStrategyTest.java @@ -0,0 +1,246 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.algo; + +import static org.junit.Assert.assertEquals; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Random; + +import org.junit.Test; + +import algorithms.acceptors.SolutionAcceptor; +import algorithms.selectors.SolutionSelector; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.SearchStrategy; +import basics.algo.SearchStrategyModule; +import basics.algo.SearchStrategyModuleListener; + + + +public class SearchStrategyTest { + + @Test(expected=IllegalStateException.class) + public void whenANullModule_IsAdded_throwException(){ + SolutionSelector select = mock(SolutionSelector.class); + SolutionAcceptor accept = mock(SolutionAcceptor.class); + + SearchStrategy strat = new SearchStrategy(select, accept); + strat.addModule(null); + + } + + @Test + public void whenStratRunsWithOneModule_runItOnes(){ + SolutionSelector select = mock(SolutionSelector.class); + SolutionAcceptor accept = mock(SolutionAcceptor.class); + + final VehicleRoutingProblem vrp = mock(VehicleRoutingProblem.class); + final VehicleRoutingProblemSolution newSol = mock(VehicleRoutingProblemSolution.class); + + when(select.selectSolution(null)).thenReturn(newSol); + + final Collection runs = new ArrayList(); + + SearchStrategy strat = new SearchStrategy(select, accept); + SearchStrategyModule mod = new SearchStrategyModule() { + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + runs.add(1); + return vrpSolution; + } + + @Override + public String getName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void addModuleListener( + SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } + }; + strat.addModule(mod); + strat.run(vrp, null); + + assertEquals(runs.size(), 1); + } + + @Test + public void whenStratRunsWithTwoModule_runItTwice(){ + SolutionSelector select = mock(SolutionSelector.class); + SolutionAcceptor accept = mock(SolutionAcceptor.class); + + final VehicleRoutingProblem vrp = mock(VehicleRoutingProblem.class); + final VehicleRoutingProblemSolution newSol = mock(VehicleRoutingProblemSolution.class); + + when(select.selectSolution(null)).thenReturn(newSol); + + final Collection runs = new ArrayList(); + + SearchStrategy strat = new SearchStrategy(select, accept); + + SearchStrategyModule mod = new SearchStrategyModule() { + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + runs.add(1); + return vrpSolution; + } + + @Override + public String getName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void addModuleListener( + SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } + }; + SearchStrategyModule mod2 = new SearchStrategyModule() { + + @Override + public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { + runs.add(1); + return vrpSolution; + } + + @Override + public String getName() { + // TODO Auto-generated method stub + return null; + } + + @Override + public void addModuleListener( + SearchStrategyModuleListener moduleListener) { + // TODO Auto-generated method stub + + } + }; + strat.addModule(mod); + strat.addModule(mod2); + strat.run(vrp, null); + + assertEquals(runs.size(), 2); + } + + @Test + public void whenStratRunsWithNModule_runItNTimes(){ + SolutionSelector select = mock(SolutionSelector.class); + SolutionAcceptor accept = mock(SolutionAcceptor.class); + + final VehicleRoutingProblem vrp = mock(VehicleRoutingProblem.class); + final VehicleRoutingProblemSolution newSol = mock(VehicleRoutingProblemSolution.class); + + when(select.selectSolution(null)).thenReturn(newSol); + + int N = new Random().nextInt(1000); + + final Collection runs = new ArrayList(); + + SearchStrategy strat = new SearchStrategy(select, accept); + + for(int i=0;i runs = new ArrayList(); + + SearchStrategy strat = new SearchStrategy(select, accept); + + for(int i=0;i()).read("src/test/resources/lui-shen-solution.xml"); + + } + +} diff --git a/jsprit-core/src/test/java/basics/io/VrpReaderV2Test.java b/jsprit-core/src/test/java/basics/io/VrpReaderV2Test.java new file mode 100644 index 00000000..e666cbb6 --- /dev/null +++ b/jsprit-core/src/test/java/basics/io/VrpReaderV2Test.java @@ -0,0 +1,133 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertTrue; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; +import java.util.List; + +import org.junit.Before; +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.Builder; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; +import basics.io.VrpXMLReader; +import basics.route.Vehicle; + +public class VrpReaderV2Test { + + private String inFileName; + + @Before + public void doBefore(){ + inFileName = "src/test/resources/finiteVrpForReaderV2Test.xml"; + } + + @Test + public void whenReadingVrp_problemTypeIsReadCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.FINITE,vrp.getFleetSize()); + assertEquals(FleetComposition.HETEROGENEOUS,vrp.getFleetComposition()); + } + + @Test + public void whenReadingVrp_vehiclesAreReadCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(2,vrp.getVehicles().size()); + assertTrue(idsInCollection(Arrays.asList("v1","v2"),vrp.getVehicles())); + } + + @Test + public void whenReadingVrp_vehiclesAreReadCorrectly2(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + Vehicle v1 = getVehicle("v1",vrp.getVehicles()); + assertEquals(20,v1.getCapacity()); + assertEquals(100.0,v1.getCoord().getX(),0.01); + assertEquals(0.0,v1.getEarliestDeparture(),0.01); + assertEquals("depotLoc2",v1.getLocationId()); + assertNotNull(v1.getType()); + assertEquals("vehType", v1.getType().getTypeId()); + assertEquals(1000.0,v1.getLatestArrival(),0.01); + } + + private Vehicle getVehicle(String string, Collection vehicles) { + for(Vehicle v : vehicles) if(string.equals(v.getId())) return v; + return null; + } + + private boolean idsInCollection(List asList, Collection vehicles) { + List ids = new ArrayList(asList); + for(Vehicle v : vehicles){ + if(ids.contains(v.getId())) ids.remove(v.getId()); + } + return ids.isEmpty(); + } + + @Test + public void whenReadingVrp_vehicleTypesAreReadCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(2,vrp.getTypes().size()); + } + + @Test + public void whenReadingVrpWithInfiniteSize_itReadsCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.FINITE,vrp.getFleetSize()); + } + + @Test + public void whenReadingServices_itReadsThemCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(2, vrp.getJobs().size()); + } + + @Test + public void whenReadingServices_servicesAreBuiltCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(builder, null).read(inFileName); + VehicleRoutingProblem vrp = builder.build(); + Service s1 = (Service) vrp.getJobs().get("1"); + assertEquals("delivery",s1.getType()); + assertEquals(1,s1.getCapacityDemand()); + assertEquals(0.0,s1.getServiceDuration(),0.01); + assertEquals(2, vrp.getJobs().size()); + } +} diff --git a/jsprit-core/src/test/java/basics/io/VrpWriterV2Test.java b/jsprit-core/src/test/java/basics/io/VrpWriterV2Test.java new file mode 100644 index 00000000..eae79489 --- /dev/null +++ b/jsprit-core/src/test/java/basics/io/VrpWriterV2Test.java @@ -0,0 +1,203 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import static org.junit.Assert.assertEquals; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; + +import org.junit.Before; +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.VehicleRoutingProblem.Builder; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; +import basics.io.VrpXMLReader; +import basics.io.VrpXMLWriter; +import basics.route.End; +import basics.route.ServiceActivity; +import basics.route.Start; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleRoute; +import basics.route.VehicleImpl.VehicleType; + +public class VrpWriterV2Test { + + private String infileName; + + @Before + public void doBefore(){ + infileName = "src/test/resources/infiniteWriterV2Test.xml"; + } + + + @Test + public void whenWritingInfiniteVrp_itWritesCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetComposition(FleetComposition.HETEROGENEOUS); + builder.setFleetSize(FleetSize.INFINITE); +// Depot depot = new Depot("depotLoc",Coordinate.newInstance(0, 0)); +// Depot depot2 = new Depot("depotLoc2",Coordinate.newInstance(100, 100)); +// builder.addDepot(depot2); +// builder.assignVehicleType(depot, VehicleType.Builder.newInstance("vehType", 20).build()); +// builder.assignVehicleType(depot, VehicleType.Builder.newInstance("vehType2", 200).build()); + VehicleType type = VehicleType.Builder.newInstance("vehType", 20).build(); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("myVehicle").setLocationId("loc").setType(type).build(); + builder.addVehicle(vehicle); + VehicleRoutingProblem vrp = builder.build(); + new VrpXMLWriter(vrp, null).write(infileName); + } + + @Test + public void whenWritingFiniteVrp_itWritesCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetComposition(FleetComposition.HETEROGENEOUS); + builder.setFleetSize(FleetSize.FINITE); +// Depot depot = new Depot("depotLoc",Coordinate.newInstance(0, 0)); +// Depot depot2 = new Depot("depotLoc2",Coordinate.newInstance(100, 100)); +// builder.addDepot(depot2); + VehicleType type1 = VehicleType.Builder.newInstance("vehType", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("vehType2", 200).build(); + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("loc").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("loc").setType(type2).build(); + builder.addVehicleType(type1); + builder.addVehicleType(type2); + builder.addVehicle(v1); + builder.addVehicle(v2); + VehicleRoutingProblem vrp = builder.build(); + new VrpXMLWriter(vrp, null).write(infileName); + } + + @Test + public void t(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetComposition(FleetComposition.HETEROGENEOUS); + builder.setFleetSize(FleetSize.FINITE); +// Depot depot = new Depot("depotLoc",Coordinate.newInstance(0, 0)); +// Depot depot2 = new Depot("depotLoc2",Coordinate.newInstance(100, 100)); +// builder.addDepot(depot2); + VehicleType type1 = VehicleType.Builder.newInstance("vehType", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("vehType2", 200).build(); + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("loc").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("loc").setType(type2).build(); + builder.addVehicleType(type1); + builder.addVehicleType(type2); + builder.addVehicle(v1); + builder.addVehicle(v2); + VehicleRoutingProblem vrp = builder.build(); + new VrpXMLWriter(vrp, null).write(infileName); + + VehicleRoutingProblem.Builder vrpToReadBuilder = VehicleRoutingProblem.Builder.newInstance(); + new VrpXMLReader(vrpToReadBuilder, null).read(infileName); + } + + @Test + public void whenWritingServices_itWritesThemCorrectly(){ + Builder builder = VehicleRoutingProblem.Builder.newInstance(); + + VehicleType type1 = VehicleType.Builder.newInstance("vehType", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("vehType2", 200).build(); + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("loc").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("loc").setType(type2).build(); + + builder.addVehicleType(type1); + builder.addVehicleType(type2); + builder.addVehicle(v1); + builder.addVehicle(v2); + + Service s1 = Service.Builder.newInstance("1", 1).setLocationId("loc").setName("delivery").setServiceTime(2.0).build(); + Service s2 = Service.Builder.newInstance("2", 1).setLocationId("loc2").setName("delivery").setServiceTime(4.0).build(); + + VehicleRoutingProblem vrp = builder.addService(s1).addService(s2).build(); + new VrpXMLWriter(vrp, null).write(infileName); + + VehicleRoutingProblem.Builder vrpToReadBuilder = builder; + new VrpXMLReader(vrpToReadBuilder, null).read(infileName); + VehicleRoutingProblem readVrp = vrpToReadBuilder.build(); + assertEquals(2,readVrp.getJobs().size()); + + Service s1_read = (Service) vrp.getJobs().get("1"); + assertEquals("1", s1_read.getId()); + assertEquals("loc", s1_read.getLocationId()); + assertEquals("delivery", s1_read.getType()); + assertEquals(2.0,s1_read.getServiceDuration(),0.01); + } + + @Test + public void whenWritingSolutions_itWritesThemCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetComposition(FleetComposition.HETEROGENEOUS); + builder.setFleetSize(FleetSize.FINITE); + VehicleType type1 = VehicleType.Builder.newInstance("vehType", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("vehType2", 200).build(); + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("loc").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("loc").setType(type2).build(); + builder.addVehicleType(type1); + builder.addVehicleType(type2); + builder.addVehicle(v1); + builder.addVehicle(v2); + + Service s1 = Service.Builder.newInstance("1", 1).setLocationId("loc").setName("delivery").setServiceTime(2.0).build(); + Service s2 = Service.Builder.newInstance("2", 1).setLocationId("loc2").setName("delivery").setServiceTime(4.0).build(); + builder.addService(s1).addService(s2); + + VehicleRoutingProblem vrp = builder.build(); + + Collection routes = new ArrayList(); + Start start = Start.newInstance("start", 0.0, Double.MAX_VALUE); + start.setEndTime(10.0); + End end = End.newInstance("end", 0.0, Double.MAX_VALUE); + end.setArrTime(100); + VehicleRoute.Builder routebuilder = VehicleRoute.Builder.newInstance(start, end); + + ServiceActivity act1 = ServiceActivity.newInstance(s1); + ServiceActivity act2 = ServiceActivity.newInstance(s2); + act1.setArrTime(20.0); + act1.setEndTime(30.0); + + act2.setArrTime(40.0); + act2.setEndTime(80.0); + + routebuilder.addActivity(act1).addActivity(act2).setVehicle(v1); + VehicleRoute route = routebuilder.build(); + routes.add(route); + + VehicleRoutingProblemSolution solution = new VehicleRoutingProblemSolution(routes, 100); + + new VrpXMLWriter(vrp, Arrays.asList(solution)).write(infileName); + + VehicleRoutingProblem.Builder vrpToReadBuilder = VehicleRoutingProblem.Builder.newInstance(); + Collection solutions = new ArrayList(); + new VrpXMLReader(vrpToReadBuilder, solutions).read(infileName); + + VehicleRoutingProblem readVrp = vrpToReadBuilder.build(); + + assertEquals(1, solutions.size()); + + } + +} diff --git a/jsprit-core/src/test/java/basics/io/VrpWriterV3Test.java b/jsprit-core/src/test/java/basics/io/VrpWriterV3Test.java new file mode 100644 index 00000000..79753430 --- /dev/null +++ b/jsprit-core/src/test/java/basics/io/VrpWriterV3Test.java @@ -0,0 +1,107 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.io; + +import static org.junit.Assert.assertEquals; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Collection; + +import org.junit.Before; +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.Service.Builder; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; +import basics.io.VrpXMLReader; +import basics.io.VrpXMLWriter; +import basics.route.End; +import basics.route.ServiceActivity; +import basics.route.Start; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleRoute; +import basics.route.VehicleImpl.VehicleType; + +public class VrpWriterV3Test { + + private String infileName; + + @Before + public void doBefore(){ + infileName = "src/test/resources/infiniteWriterV2Test.xml"; + } + + @Test + public void whenWritingSolutions_itWritesThemCorrectly(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + builder.setFleetComposition(FleetComposition.HETEROGENEOUS); + builder.setFleetSize(FleetSize.FINITE); + VehicleType type1 = VehicleType.Builder.newInstance("vehType", 20).build(); + VehicleType type2 = VehicleType.Builder.newInstance("vehType2", 200).build(); + Vehicle v1 = VehicleImpl.VehicleBuilder.newInstance("v1").setLocationId("loc").setType(type1).build(); + Vehicle v2 = VehicleImpl.VehicleBuilder.newInstance("v2").setLocationId("loc").setType(type2).build(); + builder.addVehicleType(type1); + builder.addVehicleType(type2); + builder.addVehicle(v1); + builder.addVehicle(v2); + + Service s1 = Service.Builder.newInstance("1", 1).setLocationId("loc").setName("delivery").setServiceTime(2.0).build(); + Service s2 = Service.Builder.newInstance("2", 1).setLocationId("loc2").setName("delivery").setServiceTime(4.0).build(); + builder.addService(s1).addService(s2); + + VehicleRoutingProblem vrp = builder.build(); + + Collection routes = new ArrayList(); + Start start = Start.newInstance("start", 0.0, Double.MAX_VALUE); + start.setEndTime(10.0); + End end = End.newInstance("end", 0.0, Double.MAX_VALUE); + end.setArrTime(100); + VehicleRoute.Builder routebuilder = VehicleRoute.Builder.newInstance(start, end); + + ServiceActivity act1 = ServiceActivity.newInstance(s1); + ServiceActivity act2 = ServiceActivity.newInstance(s2); + act1.setArrTime(20.0); + act1.setEndTime(30.0); + + act2.setArrTime(40.0); + act2.setEndTime(80.0); + + routebuilder.addActivity(act1).addActivity(act2).setVehicle(v1); + VehicleRoute route = routebuilder.build(); + routes.add(route); + + VehicleRoutingProblemSolution solution = new VehicleRoutingProblemSolution(routes, 100); + + new VrpXMLWriter(vrp, Arrays.asList(solution)).write(infileName); + + VehicleRoutingProblem.Builder vrpToReadBuilder = VehicleRoutingProblem.Builder.newInstance(); + Collection solutions = new ArrayList(); + new VrpXMLReader(vrpToReadBuilder, solutions).read(infileName); + VehicleRoutingProblem readVrp = vrpToReadBuilder.build(); + + } + +} diff --git a/jsprit-core/src/test/java/basics/route/ServiceActTest.java b/jsprit-core/src/test/java/basics/route/ServiceActTest.java new file mode 100644 index 00000000..37050843 --- /dev/null +++ b/jsprit-core/src/test/java/basics/route/ServiceActTest.java @@ -0,0 +1,54 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import static org.junit.Assert.*; + +import org.junit.Test; + +import basics.Service; +import basics.Service.Builder; +import basics.route.ServiceActivity; + +public class ServiceActTest { + + @Test + public void whenTwoDeliveriesHaveTheSameUnderlyingJob_theyAreEqual(){ + Service s1 = Service.Builder.newInstance("s", 10).setLocationId("loc").build(); + Service s2 = Service.Builder.newInstance("s", 10).setLocationId("loc").build(); + + ServiceActivity d1 = ServiceActivity.newInstance(s1); + ServiceActivity d2 = ServiceActivity.newInstance(s2); + + assertTrue(d1.equals(d2)); + } + + @Test + public void whenTwoDeliveriesHaveTheDifferentUnderlyingJob_theyAreNotEqual(){ + Service s1 = Service.Builder.newInstance("s", 10).setLocationId("loc").build(); + Service s2 = Service.Builder.newInstance("s1", 10).setLocationId("loc").build(); + + ServiceActivity d1 = ServiceActivity.newInstance(s1); + ServiceActivity d2 = ServiceActivity.newInstance(s2); + + assertFalse(d1.equals(d2)); + } +} diff --git a/jsprit-core/src/test/java/basics/route/TestTour.java b/jsprit-core/src/test/java/basics/route/TestTour.java new file mode 100644 index 00000000..8b5d6263 --- /dev/null +++ b/jsprit-core/src/test/java/basics/route/TestTour.java @@ -0,0 +1,83 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import static org.junit.Assert.*; + +import org.junit.Before; +import org.junit.Test; + +import basics.Service; +import basics.Service.Builder; +import basics.route.ServiceActivity; +import basics.route.TourActivities; + + +public class TestTour { + + private Service service; + private ServiceActivity act; + private TourActivities tour; + + @Before + public void doBefore(){ + service = Service.Builder.newInstance("yo", 10).setLocationId("loc").build(); + act = ServiceActivity.newInstance(service); + tour = new TourActivities(); + } + + @Test + public void whenAddingServiceAct_serviceActIsAdded(){ + assertFalse(tour.servesJob(service)); + tour.addActivity(act); + assertTrue(tour.servesJob(service)); + } + + @Test(expected=IllegalStateException.class) + public void whenAddingServiceActTwice_serviceActIsAdded(){ + assertFalse(tour.servesJob(service)); + tour.addActivity(act); + tour.addActivity(act); + } + + @Test + public void whenAddingServiceAndRemoveIt_tourShouldNotServeService(){ + assertFalse(tour.servesJob(service)); + tour.addActivity(act); + assertTrue(tour.servesJob(service)); + tour.removeJob(service); + assertFalse(tour.servesJob(service)); + } + + @Test + public void noNameYet(){ + assertEquals(0, tour.getActivities().size()); + tour.addActivity(act); + assertEquals(1, tour.getActivities().size()); + Service anotherServiceInstance = Service.Builder.newInstance("yo", 10).setLocationId("loc").build(); + assertTrue(service.equals(anotherServiceInstance)); + boolean removed = tour.removeJob(anotherServiceInstance); + assertTrue(removed); +// assertEquals(0, tour.getActivities().size()); + } + + +} diff --git a/jsprit-core/src/test/java/basics/route/TestVehicleRoute.java b/jsprit-core/src/test/java/basics/route/TestVehicleRoute.java new file mode 100644 index 00000000..954f714e --- /dev/null +++ b/jsprit-core/src/test/java/basics/route/TestVehicleRoute.java @@ -0,0 +1,250 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package basics.route; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; + +import java.util.Iterator; + +import org.junit.Before; +import org.junit.Test; + +import basics.Service; +import basics.Service.Builder; +import basics.route.DriverImpl; +import basics.route.ServiceActivity; +import basics.route.Start; +import basics.route.TourActivities; +import basics.route.TourActivity; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleRoute; +import basics.route.DriverImpl.NoDriver; + +public class TestVehicleRoute { + + private VehicleImpl vehicle; + private NoDriver driver; + + @Before + public void doBefore(){ + vehicle = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("loc").setType(VehicleImpl.VehicleType.Builder.newInstance("yo", 0).build()).build(); + driver = DriverImpl.noDriver(); + } + + + + @Test + public void whenBuildingEmptyRouteCorrectly_go(){ + + VehicleRoute route = VehicleRoute.newInstance(TourActivities.emptyTour(),DriverImpl.noDriver(),VehicleImpl.noVehicle()); + assertTrue(true); + } + + @Test + public void whenBuildingEmptyRouteCorrectlyV2_go(){ + + VehicleRoute route = VehicleRoute.emptyRoute(); + assertTrue(true); + } + + @Test + public void whenBuildingEmptyRoute_ActivityIteratorIteratesOverZeroActivities(){ + VehicleRoute route = VehicleRoute.emptyRoute(); + Iterator iter = route.getTourActivities().iterator(); + int count=0; + while(iter.hasNext()){ + iter.next(); + count++; + } + assertEquals(0,count); + } + + @Test(expected=IllegalStateException.class) + public void whenBuildingEmptyRoute_(){ + + VehicleRoute route = VehicleRoute.newInstance(null,null,null); + + } + + @Test(expected=IllegalStateException.class) + public void whenBuildingRouteWithNonEmptyTour_throwException(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("jo", 10).build())); + VehicleRoute route = VehicleRoute.newInstance(tour,DriverImpl.noDriver(),VehicleImpl.noVehicle()); + + } + + @Test + public void whenBuildingEmptyTour_tourIterIteratesOverAnEmptyList(){ + TourActivities tour = new TourActivities(); + Vehicle v = VehicleImpl.VehicleBuilder.newInstance("v").setLocationId("loc").setType(VehicleImpl.VehicleType.Builder.newInstance("yo", 0).build()).build(); + VehicleRoute route = VehicleRoute.newInstance(tour,DriverImpl.noDriver(),v); + Iterator iter = route.getTourActivities().iterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(0,count); + } + + @Test + public void whenBuildingANonEmptyTour_tourIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(Start.newInstance("", 0, 0)); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + Iterator iter = route.getTourActivities().iterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(1,count); + } + + + @Test + public void whenBuildingANonEmptyTour2Times_tourIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("2", 30).setLocationId("1").build())); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + + { + Iterator iter = route.getTourActivities().iterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(1,count); + } + { + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("3", 30).setLocationId("1").build())); + Iterator iter = route.getTourActivities().iterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(2,count); + } + } + + @Test + public void whenBuildingANonEmptyTour_tourReverseIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + Iterator iter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(0,count); + } + + @Test + public void whenBuildingANonEmptyTourV2_tourReverseIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("2", 30).setLocationId("1").build())); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + Iterator iter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + while(iter.hasNext()){ + TourActivity act = iter.next(); + count++; + } + assertEquals(1,count); + } + + @Test + public void whenBuildingANonEmptyTourV3_tourReverseIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("2", 30).setLocationId("1").build())); + ServiceActivity del = ServiceActivity.newInstance(Service.Builder.newInstance("3", 30).setLocationId("1").build()); + tour.addActivity(del); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + Iterator iter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + TourActivity memAct = null; + while(iter.hasNext()){ + TourActivity act = iter.next(); + if(count==0) memAct = act; + count++; + } + assertEquals(memAct,del); + } + + @Test + public void whenBuildingANonEmptyTourV4_tourReverseIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("2", 30).setLocationId("1").build())); + ServiceActivity del = ServiceActivity.newInstance(Service.Builder.newInstance("3", 30).setLocationId("1").build()); + tour.addActivity(del); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + Iterator iter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + TourActivity memAct = null; + while(iter.hasNext()){ + TourActivity act = iter.next(); + if(count==0) memAct = act; + count++; + } + assertEquals(memAct,del); + assertEquals(2,count); + } + + @Test + public void whenBuildingANonEmptyTour2Times_tourReverseIterIteratesOverActivitiesCorrectly(){ + TourActivities tour = new TourActivities(); + tour.addActivity(ServiceActivity.newInstance(Service.Builder.newInstance("2", 30).setLocationId("1").build())); + ServiceActivity del = ServiceActivity.newInstance(Service.Builder.newInstance("3", 30).setLocationId("1").build()); + tour.addActivity(del); + VehicleRoute route = VehicleRoute.newInstance(tour, driver, vehicle); + { + Iterator iter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + TourActivity memAct = null; + while(iter.hasNext()){ + TourActivity act = iter.next(); + if(count==0) memAct = act; + count++; + } + assertEquals(memAct,del); + assertEquals(2,count); + } + { + Iterator secondIter = route.getTourActivities().reverseActivityIterator(); + int count = 0; + TourActivity memAct = null; + while(secondIter.hasNext()){ + TourActivity act = secondIter.next(); + if(count==0) memAct = act; + count++; + } + assertEquals(memAct,del); + assertEquals(2,count); + } + } + +} diff --git a/jsprit-core/src/test/resources/algorithmConfig.xml b/jsprit-core/src/test/resources/algorithmConfig.xml new file mode 100755 index 00000000..c2d37219 --- /dev/null +++ b/jsprit-core/src/test/resources/algorithmConfig.xml @@ -0,0 +1,67 @@ + + + + + 2000 + + + + + + + 1 + + + + + + + + 0.5 + + + + + + 0.5 + + + + + + + + + 0.3 + + + + + + 0.5 + + + + + + diff --git a/jsprit-core/src/test/resources/algorithmConfigWithDepartureTimeChoice.xml b/jsprit-core/src/test/resources/algorithmConfigWithDepartureTimeChoice.xml new file mode 100755 index 00000000..2e7fee5f --- /dev/null +++ b/jsprit-core/src/test/resources/algorithmConfigWithDepartureTimeChoice.xml @@ -0,0 +1,84 @@ + + + + + 2000 + + + + + + + 1 + + + + + + + + 0.5 + + + + + + 0.4 + + + + + + + + + 0.3 + + + + + + 0.4 + + + + + + + + + 0.1 + + + + + + + + 0.2 + + + + + + diff --git a/jsprit-core/src/test/resources/algorithmConfig_withoutIterations.xml b/jsprit-core/src/test/resources/algorithmConfig_withoutIterations.xml new file mode 100755 index 00000000..30d57cc3 --- /dev/null +++ b/jsprit-core/src/test/resources/algorithmConfig_withoutIterations.xml @@ -0,0 +1,67 @@ + + + + + + + + + + 1 + + + + + + + + + 0.5 + + + + + + 0.5 + + + + + + + + + 0.3 + + + + + + 0.5 + + + + + + + diff --git a/jsprit-core/src/test/resources/configWithRegretInsertion.xml b/jsprit-core/src/test/resources/configWithRegretInsertion.xml new file mode 100755 index 00000000..fa735ca3 --- /dev/null +++ b/jsprit-core/src/test/resources/configWithRegretInsertion.xml @@ -0,0 +1,91 @@ + + + + + 10 + + + + + + + + 1 + + + + + + + + 0.5 + + + + + 0.4 + + + + + + + + + 0.1 + + + + + 0.4 + + + + + + + + + 0.3 + + + + + 0.2 + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/src/test/resources/finiteVrpForReaderV2Test.xml b/jsprit-core/src/test/resources/finiteVrpForReaderV2Test.xml new file mode 100644 index 00000000..20d9e7a0 --- /dev/null +++ b/jsprit-core/src/test/resources/finiteVrpForReaderV2Test.xml @@ -0,0 +1,106 @@ + + + + + FINITE + HETEROGENEOUS + + + + + v1 + + depotLoc2 + + + vehType + + 0.0 + 1000.0 + + + + v2 + + depotLoc + + + vehType2 + + 0.0 + 1000.0 + + + + + + vehType + 20 + + 0.0 + 0.0 + + + + + vehType2 + 200 + + 0.0 + 0.0 + + + + + + + + j(1,5) + + 1 + 0.0 + + + 0.0 + 4000.0 + + + + + + i(3,9) + + 1 + 0.0 + + + 0.0 + 4000.0 + + + + + + + diff --git a/jsprit-core/src/test/resources/infiniteWriterV2Test.xml b/jsprit-core/src/test/resources/infiniteWriterV2Test.xml new file mode 100644 index 00000000..57f824f6 --- /dev/null +++ b/jsprit-core/src/test/resources/infiniteWriterV2Test.xml @@ -0,0 +1,100 @@ + + + + FINITE + HETEROGENEOUS + + + + v1 + vehType + + loc + + + 0.0 + 1.7976931348623157E308 + + + + v2 + vehType2 + + loc + + + 0.0 + 1.7976931348623157E308 + + + + + + vehType + 20 + + 0.0 + 0.0 + + + + + vehType2 + 200 + + 0.0 + 0.0 + + + + + + + loc2 + 1 + 4.0 + + + 0.0 + 1.7976931348623157E308 + + + + + loc + 1 + 2.0 + + + 0.0 + 1.7976931348623157E308 + + + + + + + 100.0 + + + 0.0 + noDriver + v1 + 10.0 + + 1 + 20.0 + 30.0 + + + 2 + 40.0 + 80.0 + + 100.0 + + + + + diff --git a/jsprit-core/src/test/resources/lui-shen-solution.xml b/jsprit-core/src/test/resources/lui-shen-solution.xml new file mode 100644 index 00000000..74948e25 --- /dev/null +++ b/jsprit-core/src/test/resources/lui-shen-solution.xml @@ -0,0 +1,1937 @@ + + + + + INFINITE + HETEROGENEOUS + + + + A + A + + 0 + + + + 0.0 + 1236.0 + + + + B + B + + 0 + + + + 0.0 + 1236.0 + + + + C + C + + 0 + + + + 0.0 + 1236.0 + + + + + + A + 100 + + 300.0 + 1.0 + + + + + B + 200 + + 800.0 + 1.0 + + + + + C + 300 + + 1350.0 + 1.0 + + + + + + + 25 + + 40 + 90.0 + + + 169.0 + 224.0 + + + + + 26 + + 10 + 90.0 + + + 622.0 + 701.0 + + + + + 23 + + 10 + 90.0 + + + 732.0 + 777.0 + + + + + 24 + + 10 + 90.0 + + + 65.0 + 144.0 + + + + + 29 + + 10 + 90.0 + + + 358.0 + 405.0 + + + + + 27 + + 10 + 90.0 + + + 261.0 + 316.0 + + + + + 28 + + 20 + 90.0 + + + 546.0 + 593.0 + + + + + 33 + + 40 + 90.0 + + + 87.0 + 158.0 + + + + + 32 + + 30 + 90.0 + + + 31.0 + 100.0 + + + + + 31 + + 20 + 90.0 + + + 200.0 + 237.0 + + + + + 30 + + 10 + 90.0 + + + 449.0 + 504.0 + + + + + 12 + + 20 + 90.0 + + + 652.0 + 721.0 + + + + + 13 + + 30 + 90.0 + + + 30.0 + 92.0 + + + + + 14 + + 10 + 90.0 + + + 567.0 + 620.0 + + + + + 15 + + 40 + 90.0 + + + 384.0 + 429.0 + + + + + 16 + + 40 + 90.0 + + + 475.0 + 528.0 + + + + + 17 + + 20 + 90.0 + + + 99.0 + 148.0 + + + + + 18 + + 20 + 90.0 + + + 179.0 + 254.0 + + + + + 19 + + 10 + 90.0 + + + 278.0 + 345.0 + + + + + 20 + + 10 + 90.0 + + + 10.0 + 73.0 + + + + + 22 + + 20 + 90.0 + + + 812.0 + 883.0 + + + + + 21 + + 20 + 90.0 + + + 914.0 + 965.0 + + + + + 9 + + 10 + 90.0 + + + 534.0 + 605.0 + + + + + 7 + + 20 + 90.0 + + + 170.0 + 225.0 + + + + + 8 + + 20 + 90.0 + + + 255.0 + 324.0 + + + + + 5 + + 10 + 90.0 + + + 15.0 + 67.0 + + + + + 6 + + 20 + 90.0 + + + 621.0 + 702.0 + + + + + 3 + + 10 + 90.0 + + + 65.0 + 146.0 + + + + + 4 + + 10 + 90.0 + + + 727.0 + 782.0 + + + + + 1 + + 10 + 90.0 + + + 912.0 + 967.0 + + + + + 2 + + 30 + 90.0 + + + 825.0 + 870.0 + + + + + 11 + + 10 + 90.0 + + + 448.0 + 505.0 + + + + + 10 + + 10 + 90.0 + + + 357.0 + 410.0 + + + + + 99 + + 10 + 90.0 + + + 743.0 + 820.0 + + + + + 98 + + 20 + 90.0 + + + 30.0 + 84.0 + + + + + 97 + + 30 + 90.0 + + + 561.0 + 622.0 + + + + + 96 + + 10 + 90.0 + + + 95.0 + 156.0 + + + + + 95 + + 30 + 90.0 + + + 196.0 + 239.0 + + + + + 94 + + 10 + 90.0 + + + 285.0 + 336.0 + + + + + 93 + + 40 + 90.0 + + + 475.0 + 518.0 + + + + + 89 + + 10 + 90.0 + + + 737.0 + 802.0 + + + + + 92 + + 20 + 90.0 + + + 368.0 + 441.0 + + + + + 91 + + 10 + 90.0 + + + 836.0 + 889.0 + + + + + 90 + + 10 + 90.0 + + + 20.0 + 84.0 + + + + + 88 + + 30 + 90.0 + + + 645.0 + 708.0 + + + + + 87 + + 20 + 90.0 + + + 85.0 + 144.0 + + + + + 86 + + 10 + 90.0 + + + 173.0 + 238.0 + + + + + 85 + + 30 + 90.0 + + + 555.0 + 612.0 + + + + + 84 + + 20 + 90.0 + + + 458.0 + 523.0 + + + + + 83 + + 10 + 90.0 + + + 265.0 + 338.0 + + + + + 82 + + 20 + 90.0 + + + 369.0 + 420.0 + + + + + 81 + + 30 + 90.0 + + + 47.0 + 124.0 + + + + + 80 + + 10 + 90.0 + + + 769.0 + 820.0 + + + + + 78 + + 20 + 90.0 + + + 109.0 + 170.0 + + + + + 79 + + 10 + 90.0 + + + 668.0 + 731.0 + + + + + 69 + + 10 + 90.0 + + + 916.0 + 969.0 + + + + + 68 + + 10 + 90.0 + + + 734.0 + 777.0 + + + + + 67 + + 10 + 90.0 + + + 12.0 + 77.0 + + + + + 100 + + 20 + 90.0 + + + 647.0 + 726.0 + + + + + 72 + + 10 + 90.0 + + + 450.0 + 505.0 + + + + + 73 + + 10 + 90.0 + + + 478.0 + 551.0 + + + + + 70 + + 30 + 90.0 + + + 387.0 + 456.0 + + + + + 71 + + 20 + 90.0 + + + 293.0 + 360.0 + + + + + 76 + + 10 + 90.0 + + + 203.0 + 260.0 + + + + + 77 + + 10 + 90.0 + + + 574.0 + 643.0 + + + + + 74 + + 50 + 90.0 + + + 353.0 + 412.0 + + + + + 75 + + 20 + 90.0 + + + 997.0 + 1068.0 + + + + + 57 + + 40 + 90.0 + + + 35.0 + 87.0 + + + + + 56 + + 30 + 90.0 + + + 385.0 + 436.0 + + + + + 59 + + 10 + 90.0 + + + 651.0 + 740.0 + + + + + 58 + + 30 + 90.0 + + + 471.0 + 534.0 + + + + + 60 + + 20 + 90.0 + + + 562.0 + 629.0 + + + + + 61 + + 10 + 90.0 + + + 531.0 + 610.0 + + + + + 62 + + 20 + 90.0 + + + 262.0 + 317.0 + + + + + 63 + + 50 + 90.0 + + + 171.0 + 218.0 + + + + + 64 + + 10 + 90.0 + + + 632.0 + 693.0 + + + + + 65 + + 10 + 90.0 + + + 76.0 + 129.0 + + + + + 66 + + 10 + 90.0 + + + 826.0 + 875.0 + + + + + 49 + + 10 + 90.0 + + + 1001.0 + 1066.0 + + + + + 48 + + 10 + 90.0 + + + 632.0 + 693.0 + + + + + 47 + + 10 + 90.0 + + + 1054.0 + 1127.0 + + + + + 46 + + 30 + 90.0 + + + 448.0 + 509.0 + + + + + 45 + + 10 + 90.0 + + + 541.0 + 600.0 + + + + + 54 + + 40 + 90.0 + + + 186.0 + 257.0 + + + + + 55 + + 10 + 90.0 + + + 95.0 + 158.0 + + + + + 52 + + 10 + 90.0 + + + 912.0 + 969.0 + + + + + 53 + + 20 + 90.0 + + + 286.0 + 347.0 + + + + + 50 + + 10 + 90.0 + + + 815.0 + 880.0 + + + + + 51 + + 10 + 90.0 + + + 725.0 + 786.0 + + + + + 39 + + 20 + 90.0 + + + 567.0 + 624.0 + + + + + 38 + + 30 + 90.0 + + + 479.0 + 522.0 + + + + + 35 + + 10 + 90.0 + + + 283.0 + 344.0 + + + + + 34 + + 20 + 90.0 + + + 751.0 + 816.0 + + + + + 37 + + 20 + 90.0 + + + 383.0 + 434.0 + + + + + 36 + + 10 + 90.0 + + + 665.0 + 716.0 + + + + + 41 + + 10 + 90.0 + + + 166.0 + 235.0 + + + + + 42 + + 20 + 90.0 + + + 68.0 + 149.0 + + + + + 43 + + 10 + 90.0 + + + 16.0 + 80.0 + + + + + 44 + + 10 + 90.0 + + + 359.0 + 412.0 + + + + + 40 + + 10 + 90.0 + + + 264.0 + 321.0 + + + + + + + 7482.673139970934 + + + 370.48433957246027 + noDriver + A + 0.0 + + 77 + 12.206555615733702 + 102.2065556157337 + + + 75 + 103.2065556157337 + 193.2065556157337 + + + 72 + 198.5917204228682 + 352.0 + + + 82 + 357.8309518948453 + 540.0 + + + 71 + 543.0 + 633.0 + + + 74 + 635.0 + 725.0 + + + 78 + 728.0 + 824.0 + + + 76 + 829.3851648071345 + 919.3851648071345 + + + 79 + 921.3851648071345 + 1011.3851648071345 + + 1027.1965531079763 + + + 360.9658621457393 + noDriver + A + 0.0 + + 73 + 14.142135623730951 + 261.0 + + + 84 + 266.8309518948453 + 443.0 + + 462.8494332412792 + + + 336.11724276862367 + noDriver + A + 0.0 + + 30 + 10.0 + 100.0 + + + 34 + 105.0 + 195.0 + + + 35 + 197.0 + 287.0 + + + 37 + 289.0 + 379.0 + + 396.11724276862367 + + + 396.97072464514815 + noDriver + A + 0.0 + + 67 + 35.0 + 125.0 + + + 64 + 130.38516480713452 + 276.0 + + + 63 + 281.3851648071345 + 376.0 + + 421.1774279923061 + + + 420.72702457661836 + noDriver + A + 0.0 + + 65 + 35.05709628591621 + 185.0 + + + 66 + 195.19803902718556 + 475.0 + + + 68 + 477.0 + 567.0 + + + 70 + 570.0 + 660.0 + + + 69 + 670.4403065089106 + 760.4403065089106 + + 795.4974027948268 + + + 382.09803902718556 + noDriver + A + 0.0 + + 39 + 20.0 + 448.0 + + + 40 + 453.0 + 543.0 + + + 38 + 546.0 + 636.0 + + + 36 + 638.0 + 728.0 + + + 33 + 731.0 + 822.0 + + + 32 + 825.0 + 915.0 + + + 31 + 917.0 + 1007.0 + + 1017.1980390271856 + + + 382.08680693813784 + noDriver + A + 0.0 + + 42 + 31.622776601683793 + 121.6227766016838 + + + 43 + 123.6227766016838 + 213.6227766016838 + + + 41 + 219.0079414088183 + 309.0079414088183 + + + 45 + 314.0079414088183 + 404.0079414088183 + + 442.08680693813784 + + + 421.4526583493026 + noDriver + A + 0.0 + + 47 + 39.293765408777 + 473.0 + + + 48 + 475.0 + 569.0 + + + 49 + 574.0 + 664.0 + + + 46 + 669.0 + 759.0 + + + 44 + 762.0 + 852.0 + + 884.3882694814033 + + + 396.9751783773217 + noDriver + A + 0.0 + + 108 + 30.805843601498726 + 120.80584360149872 + + + 106 + 126.19100840863322 + 216.19100840863322 + + + 104 + 221.57617321576774 + 375.0 + + + 102 + 378.605551275464 + 468.605551275464 + + + 103 + 470.605551275464 + 565.0 + + 608.0116263352131 + + + 442.4061783214535 + noDriver + A + 0.0 + + 86 + 52.20153254455275 + 293.0 + + + 81 + 298.0 + 388.0 + + + 80 + 393.0 + 483.0 + + + 83 + 486.0 + 576.0 + + + 87 + 580.0 + 670.0 + + + 89 + 671.0 + 761.0 + + + 90 + 766.3851648071345 + 859.0 + + 910.478150704935 + + + 348.0936045857849 + noDriver + A + 0.0 + + 53 + 16.55294535724685 + 106.55294535724684 + + + 52 + 109.55294535724684 + 199.55294535724684 + + + 51 + 201.55294535724684 + 291.5529453572468 + + + 50 + 293.5529453572468 + 383.5529453572468 + + + 54 + 386.5529453572468 + 476.5529453572468 + + 498.0936045857848 + + + 398.9184017049979 + noDriver + A + 0.0 + + 56 + 20.591260281974 + 538.0 + + + 55 + 540.0 + 631.0 + + + 58 + 633.0 + 723.0 + + + 61 + 726.0 + 816.0 + + + 60 + 818.2360679774998 + 908.2360679774998 + + + 62 + 911.3983456376682 + 1002.0 + + + 59 + 1005.0 + 1095.0 + + + 57 + 1097.0 + 1187.0 + + 1205.02775637732 + + + 390.48077199598873 + noDriver + A + 0.0 + + 23 + 30.805843601498726 + 120.80584360149872 + + + 28 + 127.80584360149872 + 269.0 + + + 29 + 274.0 + 368.0 + + + 25 + 373.0 + 474.0 + + 510.0555127546399 + + + 440.799048628923 + noDriver + A + 0.0 + + 27 + 33.301651610693426 + 189.0 + + + 26 + 199.19803902718556 + 565.0 + + + 24 + 567.0 + 657.0 + + + 22 + 660.0 + 750.0 + + + 109 + 780.4138126514911 + 870.4138126514911 + + 903.9548323139879 + + + 417.70181023477153 + noDriver + A + 0.0 + + 91 + 47.43416490252569 + 137.43416490252568 + + + 88 + 140.43416490252568 + 230.43416490252568 + + + 93 + 256.0466618522571 + 355.0 + + + 92 + 358.0 + 459.0 + + + 94 + 464.8309518948453 + 554.8309518948454 + + 585.8793012873655 + + + 347.21360705502025 + noDriver + A + 0.0 + + 15 + 15.132745950421556 + 105.13274595042155 + + + 13 + 106.13274595042155 + 196.13274595042157 + + + 17 + 198.13274595042157 + 288.13274595042157 + + + 18 + 290.9611730751678 + 380.9611730751678 + + + 20 + 384.5667243506318 + 474.5667243506318 + + + 21 + 477.5667243506318 + 567.5667243506318 + + 587.2136070550204 + + + 398.51014755711293 + noDriver + A + 0.0 + + 19 + 20.09975124224178 + 624.0 + + + 16 + 626.2360679774998 + 716.2360679774998 + + + 14 + 718.4721359549997 + 817.0 + + + 12 + 820.605551275464 + 915.0 + + + 11 + 917.0 + 1007.0 + + + 85 + 1010.0 + 1100.0 + + 1115.8113883008418 + + + 386.9734483703083 + noDriver + A + 0.0 + + 100 + 20.615528128088304 + 110.6155281280883 + + + 97 + 115.6155281280883 + 205.6155281280883 + + + 96 + 206.6155281280883 + 296.6155281280883 + + + 95 + 302.0006929352228 + 645.0 + + + 98 + 648.0 + 738.0 + + 764.9258240356726 + + + 443.6982451160345 + noDriver + A + 0.0 + + 105 + 37.20215047547655 + 286.0 + + + 107 + 291.3851648071345 + 651.0 + + + 110 + 656.0 + 746.0 + + + 99 + 774.1602556806574 + 864.1602556806574 + + + 101 + 867.7658069561214 + 957.7658069561214 + + 980.1264867311194 + + + + + diff --git a/jsprit-core/src/test/resources/testConfig.xml b/jsprit-core/src/test/resources/testConfig.xml new file mode 100755 index 00000000..149aeb5c --- /dev/null +++ b/jsprit-core/src/test/resources/testConfig.xml @@ -0,0 +1,85 @@ + + + + + 10 + + + + + + + 1 + + + + + + + 0.5 + + + + + 0.4 + + + + + + + + 0.1 + + + + 0.4 + + + + + + + + 0.3 + euclid + + + + 0.2 + + + + + + + + + + + + + + + + + diff --git a/jsprit-core/src/test/resources/testConfig2.xml b/jsprit-core/src/test/resources/testConfig2.xml new file mode 100755 index 00000000..40d130eb --- /dev/null +++ b/jsprit-core/src/test/resources/testConfig2.xml @@ -0,0 +1,85 @@ + + + + + 10 + + + + + + + 1 + + + + + + + 0.5 + + + + + 0.4 + + + + + + + + 0.1 + + + + 0.4 + + + + + + + + 0.3 + euclid + + + + 0.2 + + + + + + + + + + + + + + + + + diff --git a/jsprit-examples/.classpath b/jsprit-examples/.classpath new file mode 100644 index 00000000..61d1f114 --- /dev/null +++ b/jsprit-examples/.classpath @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-examples/.project b/jsprit-examples/.project new file mode 100644 index 00000000..2cf74c8d --- /dev/null +++ b/jsprit-examples/.project @@ -0,0 +1,23 @@ + + + jsprit-examples + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.m2e.core.maven2Nature + org.eclipse.jdt.core.javanature + + diff --git a/jsprit-examples/.settings/org.eclipse.core.resources.prefs b/jsprit-examples/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..afad9066 --- /dev/null +++ b/jsprit-examples/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding//src/test/resources=UTF-8 +encoding/=UTF-8 +encoding/src=UTF-8 diff --git a/jsprit-examples/.settings/org.eclipse.jdt.core.prefs b/jsprit-examples/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..107056a3 --- /dev/null +++ b/jsprit-examples/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,12 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/jsprit-examples/.settings/org.eclipse.m2e.core.prefs b/jsprit-examples/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/jsprit-examples/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/jsprit-examples/input/C101_solomon.txt b/jsprit-examples/input/C101_solomon.txt new file mode 100644 index 00000000..28cdccc6 --- /dev/null +++ b/jsprit-examples/input/C101_solomon.txt @@ -0,0 +1,110 @@ +C101 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 912 967 90 + 2 45 70 30 825 870 90 + 3 42 66 10 65 146 90 + 4 42 68 10 727 782 90 + 5 42 65 10 15 67 90 + 6 40 69 20 621 702 90 + 7 40 66 20 170 225 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 357 410 90 + 11 35 69 10 448 505 90 + 12 25 85 20 652 721 90 + 13 22 75 30 30 92 90 + 14 22 85 10 567 620 90 + 15 20 80 40 384 429 90 + 16 20 85 40 475 528 90 + 17 18 75 20 99 148 90 + 18 15 75 20 179 254 90 + 19 15 80 10 278 345 90 + 20 30 50 10 10 73 90 + 21 30 52 20 914 965 90 + 22 28 52 20 812 883 90 + 23 28 55 10 732 777 90 + 24 25 50 10 65 144 90 + 25 25 52 40 169 224 90 + 26 25 55 10 622 701 90 + 27 23 52 10 261 316 90 + 28 23 55 20 546 593 90 + 29 20 50 10 358 405 90 + 30 20 55 10 449 504 90 + 31 10 35 20 200 237 90 + 32 10 40 30 31 100 90 + 33 8 40 40 87 158 90 + 34 8 45 20 751 816 90 + 35 5 35 10 283 344 90 + 36 5 45 10 665 716 90 + 37 2 40 20 383 434 90 + 38 0 40 30 479 522 90 + 39 0 45 20 567 624 90 + 40 35 30 10 264 321 90 + 41 35 32 10 166 235 90 + 42 33 32 20 68 149 90 + 43 33 35 10 16 80 90 + 44 32 30 10 359 412 90 + 45 30 30 10 541 600 90 + 46 30 32 30 448 509 90 + 47 30 35 10 1054 1127 90 + 48 28 30 10 632 693 90 + 49 28 35 10 1001 1066 90 + 50 26 32 10 815 880 90 + 51 25 30 10 725 786 90 + 52 25 35 10 912 969 90 + 53 44 5 20 286 347 90 + 54 42 10 40 186 257 90 + 55 42 15 10 95 158 90 + 56 40 5 30 385 436 90 + 57 40 15 40 35 87 90 + 58 38 5 30 471 534 90 + 59 38 15 10 651 740 90 + 60 35 5 20 562 629 90 + 61 50 30 10 531 610 90 + 62 50 35 20 262 317 90 + 63 50 40 50 171 218 90 + 64 48 30 10 632 693 90 + 65 48 40 10 76 129 90 + 66 47 35 10 826 875 90 + 67 47 40 10 12 77 90 + 68 45 30 10 734 777 90 + 69 45 35 10 916 969 90 + 70 95 30 30 387 456 90 + 71 95 35 20 293 360 90 + 72 53 30 10 450 505 90 + 73 92 30 10 478 551 90 + 74 53 35 50 353 412 90 + 75 45 65 20 997 1068 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 109 170 90 + 79 87 30 10 668 731 90 + 80 85 25 10 769 820 90 + 81 85 35 30 47 124 90 + 82 75 55 20 369 420 90 + 83 72 55 10 265 338 90 + 84 70 58 20 458 523 90 + 85 68 60 30 555 612 90 + 86 66 55 10 173 238 90 + 87 65 55 20 85 144 90 + 88 65 60 30 645 708 90 + 89 63 58 10 737 802 90 + 90 60 55 10 20 84 90 + 91 60 60 10 836 889 90 + 92 67 85 20 368 441 90 + 93 65 85 40 475 518 90 + 94 65 82 10 285 336 90 + 95 62 80 30 196 239 90 + 96 60 80 10 95 156 90 + 97 60 85 30 561 622 90 + 98 58 75 20 30 84 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-examples/input/algorithmConfig_solomon.xml b/jsprit-examples/input/algorithmConfig_solomon.xml new file mode 100755 index 00000000..ca1ac2a1 --- /dev/null +++ b/jsprit-examples/input/algorithmConfig_solomon.xml @@ -0,0 +1,47 @@ + + + + + 2000 + + + + + + + 1 + + + + + + + + + 0.5 + + + + + 0.5 + + + + + + + + + 0.3 + + + + + 0.5 + + + + + + diff --git a/jsprit-examples/license.txt b/jsprit-examples/license.txt new file mode 100644 index 00000000..f258a711 --- /dev/null +++ b/jsprit-examples/license.txt @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. \ No newline at end of file diff --git a/jsprit-examples/pom.xml b/jsprit-examples/pom.xml new file mode 100644 index 00000000..a7542d84 --- /dev/null +++ b/jsprit-examples/pom.xml @@ -0,0 +1,50 @@ + + + + jsprit + jsprit-project + 0.0.1 + ../jsprit-project/pom.xml + + 4.0.0 + + jsprit-examples + + + + ${project.groupId} + jsprit-instances + ${project.version} + + + + ${project.groupId} + jsprit-core + ${project.version} + + + ${project.groupId} + jsprit-analysis + ${project.version} + + + diff --git a/jsprit-examples/src/main/java/examples/BuildYourOwnProblemExample.java b/jsprit-examples/src/main/java/examples/BuildYourOwnProblemExample.java new file mode 100644 index 00000000..4b79cef2 --- /dev/null +++ b/jsprit-examples/src/main/java/examples/BuildYourOwnProblemExample.java @@ -0,0 +1,32 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package examples; + +import basics.Service; + +public class BuildYourOwnProblemExample { + + public static void main(String[] args) { + + + } + +} diff --git a/jsprit-examples/src/main/java/examples/SolomonExample.java b/jsprit-examples/src/main/java/examples/SolomonExample.java new file mode 100644 index 00000000..02b02a33 --- /dev/null +++ b/jsprit-examples/src/main/java/examples/SolomonExample.java @@ -0,0 +1,114 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package examples; + +import java.util.Collection; + +import readers.SolomonReader; +import algorithms.VehicleRoutingAlgorithms; +import algorithms.selectors.SelectBest; +import analysis.AlgorithmSearchProgressChartListener; +import analysis.SolutionPlotter; +import analysis.SolutionPrinter; +import analysis.SolutionPrinter.Print; +import analysis.StopWatch; +import basics.VehicleRoutingAlgorithm; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblemSolution; +import basics.algo.VehicleRoutingAlgorithmListeners.Priority; +import basics.io.AlgorithmConfig; +import basics.io.AlgorithmConfigXmlReader; + +public class SolomonExample { + + public static void main(String[] args) { + + /* + * Build the problem. + * + * But define a problem-builder first. + */ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.Builder.newInstance(); + + /* + * A solomonReader reads solomon-instance files, and stores the required information in the builder. + */ + new SolomonReader(vrpBuilder).read("input/C101_solomon.txt"); + + /* + * Finally, the problem can be built. By default, transportCosts are crowFlyDistances (as usually used for vrp-instances). + */ + VehicleRoutingProblem vrp = vrpBuilder.build(); + + + /* + * Define the required vehicle-routing algorithms to solve the above problem. + * + * The algorithm can be defined and configured in an xml-file. + */ + AlgorithmConfig algorithmConfig = new AlgorithmConfig(); + new AlgorithmConfigXmlReader(algorithmConfig).read("input/algorithmConfig_solomon.xml"); + VehicleRoutingAlgorithm vra = VehicleRoutingAlgorithms.createAlgorithm(vrp, algorithmConfig); + vra.setPrematureBreak(500); + + /* + * Listen to the search-progress. + */ + vra.getAlgorithmListeners().addListener(new AlgorithmSearchProgressChartListener("output/searchProgress.png")); + + /* + * StopWatch to measure computation time. + */ + StopWatch stopWatch = new StopWatch(); + vra.getAlgorithmListeners().addListener(stopWatch,Priority.HIGH); + +// vra.setPrematureBreak(200); + /* + * Solve the problem. + * + * + */ + Collection solutions = vra.searchSolutions(); + + /* + * Retrieve best solution. + */ + VehicleRoutingProblemSolution solution = new SelectBest().selectSolution(solutions); + + /* + * Print computation time. + */ + System.out.println(stopWatch); + + /* + * Print solution. + */ + + SolutionPrinter.print(solution, Print.VERBOSE); + + /* + * Plot solution. + */ + SolutionPlotter.plotSolutionAsPNG(vrp, solution, "output/solomonSolution.png","C101"); + + } + +} diff --git a/jsprit-instances/.DS_Store b/jsprit-instances/.DS_Store new file mode 100644 index 00000000..5008ddfc Binary files /dev/null and b/jsprit-instances/.DS_Store differ diff --git a/jsprit-instances/.classpath b/jsprit-instances/.classpath new file mode 100644 index 00000000..1d0b8809 --- /dev/null +++ b/jsprit-instances/.classpath @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/jsprit-instances/.project b/jsprit-instances/.project new file mode 100644 index 00000000..98dde15c --- /dev/null +++ b/jsprit-instances/.project @@ -0,0 +1,23 @@ + + + jsprit-instances + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.m2e.core.maven2Nature + org.eclipse.jdt.core.javanature + + diff --git a/jsprit-instances/.settings/org.eclipse.core.resources.prefs b/jsprit-instances/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..afad9066 --- /dev/null +++ b/jsprit-instances/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +encoding//src/main/java=UTF-8 +encoding//src/main/resources=UTF-8 +encoding//src/test/java=UTF-8 +encoding//src/test/resources=UTF-8 +encoding/=UTF-8 +encoding/src=UTF-8 diff --git a/jsprit-instances/.settings/org.eclipse.jdt.core.prefs b/jsprit-instances/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 00000000..107056a3 --- /dev/null +++ b/jsprit-instances/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,12 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/jsprit-instances/.settings/org.eclipse.m2e.core.prefs b/jsprit-instances/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/jsprit-instances/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/jsprit-instances/instances/.DS_Store b/jsprit-instances/instances/.DS_Store new file mode 100644 index 00000000..eb2fd83b Binary files /dev/null and b/jsprit-instances/instances/.DS_Store differ diff --git a/jsprit-instances/instances/christofides/vrpinfo.txt b/jsprit-instances/instances/christofides/vrpinfo.txt new file mode 100644 index 00000000..e6e0988e --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpinfo.txt @@ -0,0 +1,47 @@ +There are currently 24 data files. + +The first set of data files are the 10 test problems from +Chapter 9 of S.Eilon, C.D.T.Watson-Gandy and N.Christofides +"Distribution management: mathematical modelling and +practical analysis" Griffin, London 1971. + +Test problems 1, 2, ..., 10 from Chapter 9 are available +in files vrp1, vrp2, ..., vrp10 respectively. + +The format of these data files is apparent from the tables +of data given in the above reference. + +The second set of data files are the 14 test problems from +Chapter 11 of N.Christofides, A.Mingozzi, P.Toth and C.Sandi +(eds) "Combinatorial optimization", John Wiley, Chichester 1979. + +Test problems 1, 2, ..., 14 from Chapter 11 are available +in files vrpnc1, vrpnc2, ..., vrpnc14 respectively. + +The format of these data files is: +number of customers, vehicle capacity, maximum route time, drop time +depot x-coordinate, depot y-coordinate +for each customer in turn: x-coordinate, y-coordinate, quantity + +Both sets of files are of size 15Kb (approximately). + + + +OTHER SOURCES + +Test data for vehicle routing problems is also available +using the Web from http://www-apache.imag.fr/~paugerat/VRP/INSTANCES + +A variety of vehicle routing problems are also available from the +elib library: +telnet elib.zib.de and login as elib +WWW access available at: +ftp://ftp.zib.de/pub/Packages/mp-testdata/index.html + + + +A full listing of the problem areas covered by OR-library can +be found in the file info + +ftp access available at mscmga.ms.ic.ac.uk +WWW access available at http://mscmga.ms.ic.ac.uk/ diff --git a/jsprit-instances/instances/christofides/vrpnc1.txt b/jsprit-instances/instances/christofides/vrpnc1.txt new file mode 100644 index 00000000..7296a49f --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc1.txt @@ -0,0 +1,52 @@ + 50 160 999999 0 + 30 40 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 diff --git a/jsprit-instances/instances/christofides/vrpnc10.txt b/jsprit-instances/instances/christofides/vrpnc10.txt new file mode 100644 index 00000000..c7368682 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc10.txt @@ -0,0 +1,201 @@ + 199 200 200 10 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 + 22 22 18 + 36 26 26 + 21 45 11 + 45 35 30 + 55 20 21 + 33 34 19 + 50 50 15 + 55 45 16 + 26 59 29 + 40 66 26 + 55 65 37 + 35 51 16 + 62 35 12 + 62 57 31 + 62 24 8 + 21 36 19 + 33 44 20 + 9 56 13 + 62 48 15 + 66 14 22 + 44 13 28 + 26 13 12 + 11 28 6 + 7 43 27 + 17 64 14 + 41 46 18 + 55 34 17 + 35 16 29 + 52 26 13 + 43 26 22 + 31 76 25 + 22 53 28 + 26 29 27 + 50 40 19 + 55 50 10 + 54 10 12 + 60 15 14 + 47 66 24 + 30 60 16 + 30 50 33 + 12 17 15 + 15 14 11 + 16 19 18 + 21 48 17 + 50 30 21 + 51 42 27 + 50 15 19 + 48 21 20 + 12 38 5 diff --git a/jsprit-instances/instances/christofides/vrpnc11.txt b/jsprit-instances/instances/christofides/vrpnc11.txt new file mode 100644 index 00000000..36a2ba65 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc11.txt @@ -0,0 +1,122 @@ + 120 200 999999 0 + 10 45 + 25 1 25 + 25 3 7 + 31 5 13 + 32 5 6 + 31 7 14 + 32 9 5 + 34 9 11 + 46 9 19 + 35 7 5 + 34 6 15 + 35 5 15 + 47 6 17 + 40 5 13 + 39 3 12 + 36 3 18 + 73 6 13 + 73 8 18 + 24 36 12 + 76 6 17 + 76 10 4 + 76 13 7 + 78 3 12 + 78 9 13 + 79 3 8 + 79 5 16 + 79 11 15 + 82 3 6 + 82 7 5 + 90 15 9 + 84 3 11 + 84 5 10 + 84 9 3 + 85 1 7 + 87 5 2 + 85 8 4 + 87 7 4 + 86 41 18 + 86 44 14 + 86 46 12 + 85 55 17 + 89 43 20 + 89 46 14 + 89 52 16 + 92 42 10 + 92 52 9 + 94 42 11 + 94 44 7 + 94 48 13 + 96 42 5 + 99 46 4 + 99 50 21 + 83 80 13 + 83 83 11 + 85 81 12 + 85 85 14 + 85 89 10 + 87 80 8 + 87 86 16 + 90 77 19 + 90 88 5 + 93 82 17 + 93 84 7 + 93 89 16 + 94 86 14 + 95 80 17 + 99 89 13 + 37 83 17 + 50 80 13 + 35 85 14 + 35 87 16 + 44 86 7 + 46 89 13 + 46 83 9 + 46 87 11 + 46 89 35 + 48 83 5 + 50 85 28 + 50 88 7 + 54 86 3 + 54 90 10 + 10 35 7 + 10 40 12 + 18 30 11 + 17 35 10 + 16 38 8 + 14 40 11 + 15 42 21 + 11 42 4 + 18 40 15 + 21 39 16 + 20 40 4 + 18 41 16 + 20 44 7 + 22 44 10 + 16 45 9 + 20 45 11 + 25 45 17 + 30 55 12 + 20 50 11 + 22 51 7 + 18 49 9 + 16 48 11 + 20 55 12 + 18 53 7 + 14 50 8 + 15 51 6 + 16 54 5 + 28 33 12 + 33 38 13 + 30 50 7 + 13 40 7 + 15 36 8 + 18 31 11 + 25 37 13 + 30 46 11 + 25 52 10 + 16 33 7 + 25 35 4 + 5 40 20 + 5 50 13 diff --git a/jsprit-instances/instances/christofides/vrpnc12.txt b/jsprit-instances/instances/christofides/vrpnc12.txt new file mode 100644 index 00000000..7ad04773 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc12.txt @@ -0,0 +1,102 @@ + 100 200 999999 0 + 40 50 + 45 68 10 + 45 70 30 + 42 66 10 + 42 68 10 + 42 65 10 + 40 69 20 + 40 66 20 + 38 68 20 + 38 70 10 + 35 66 10 + 35 69 10 + 25 85 20 + 22 75 30 + 22 85 10 + 20 80 40 + 20 85 40 + 18 75 20 + 15 75 20 + 15 80 10 + 30 50 10 + 30 52 20 + 28 52 20 + 28 55 10 + 25 50 10 + 25 52 40 + 25 55 10 + 23 52 10 + 23 55 20 + 20 50 10 + 20 55 10 + 10 35 20 + 10 40 30 + 8 40 40 + 8 45 20 + 5 35 10 + 5 45 10 + 2 40 20 + 0 40 30 + 0 45 20 + 35 30 10 + 35 32 10 + 33 32 20 + 33 35 10 + 32 30 10 + 30 30 10 + 30 32 30 + 30 35 10 + 28 30 10 + 28 35 10 + 26 32 10 + 25 30 10 + 25 35 10 + 44 5 20 + 42 10 40 + 42 15 10 + 40 5 30 + 40 15 40 + 38 5 30 + 38 15 10 + 35 5 20 + 50 30 10 + 50 35 20 + 50 40 50 + 48 30 10 + 48 40 10 + 47 35 10 + 47 40 10 + 45 30 10 + 45 35 10 + 95 30 30 + 95 35 20 + 53 30 10 + 92 30 10 + 53 35 50 + 45 65 20 + 90 35 10 + 88 30 10 + 88 35 20 + 87 30 10 + 85 25 10 + 85 35 30 + 75 55 20 + 72 55 10 + 70 58 20 + 68 60 30 + 66 55 10 + 65 55 20 + 65 60 30 + 63 58 10 + 60 55 10 + 60 60 10 + 67 85 20 + 65 85 40 + 65 82 10 + 62 80 30 + 60 80 10 + 60 85 30 + 58 75 20 + 55 80 10 + 55 85 20 diff --git a/jsprit-instances/instances/christofides/vrpnc13.txt b/jsprit-instances/instances/christofides/vrpnc13.txt new file mode 100644 index 00000000..1cd3bb2b --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc13.txt @@ -0,0 +1,122 @@ + 120 200 720 50 + 10 45 + 25 1 25 + 25 3 7 + 31 5 13 + 32 5 6 + 31 7 14 + 32 9 5 + 34 9 11 + 46 9 19 + 35 7 5 + 34 6 15 + 35 5 15 + 47 6 17 + 40 5 13 + 39 3 12 + 36 3 18 + 73 6 13 + 73 8 18 + 24 36 12 + 76 6 17 + 76 10 4 + 76 13 7 + 78 3 12 + 78 9 13 + 79 3 8 + 79 5 16 + 79 11 15 + 82 3 6 + 82 7 5 + 90 15 9 + 84 3 11 + 84 5 10 + 84 9 3 + 85 1 7 + 87 5 2 + 85 8 4 + 87 7 4 + 86 41 18 + 86 44 14 + 86 46 12 + 85 55 17 + 89 43 20 + 89 46 14 + 89 52 16 + 92 42 10 + 92 52 9 + 94 42 11 + 94 44 7 + 94 48 13 + 96 42 5 + 99 46 4 + 99 50 21 + 83 80 13 + 83 83 11 + 85 81 12 + 85 85 14 + 85 89 10 + 87 80 8 + 87 86 16 + 90 77 19 + 90 88 5 + 93 82 17 + 93 84 7 + 93 89 16 + 94 86 14 + 95 80 17 + 99 89 13 + 37 83 17 + 50 80 13 + 35 85 14 + 35 87 16 + 44 86 7 + 46 89 13 + 46 83 9 + 46 87 11 + 46 89 35 + 48 83 5 + 50 85 28 + 50 88 7 + 54 86 3 + 54 90 10 + 10 35 7 + 10 40 12 + 18 30 11 + 17 35 10 + 16 38 8 + 14 40 11 + 15 42 21 + 11 42 4 + 18 40 15 + 21 39 16 + 20 40 4 + 18 41 16 + 20 44 7 + 22 44 10 + 16 45 9 + 20 45 11 + 25 45 17 + 30 55 12 + 20 50 11 + 22 51 7 + 18 49 9 + 16 48 11 + 20 55 12 + 18 53 7 + 14 50 8 + 15 51 6 + 16 54 5 + 28 33 12 + 33 38 13 + 30 50 7 + 13 40 7 + 15 36 8 + 18 31 11 + 25 37 13 + 30 46 11 + 25 52 10 + 16 33 7 + 25 35 4 + 5 40 20 + 5 50 13 diff --git a/jsprit-instances/instances/christofides/vrpnc14.txt b/jsprit-instances/instances/christofides/vrpnc14.txt new file mode 100644 index 00000000..ca9693db --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc14.txt @@ -0,0 +1,102 @@ + 100 200 1040 90 + 40 50 + 45 68 10 + 45 70 30 + 42 66 10 + 42 68 10 + 42 65 10 + 40 69 20 + 40 66 20 + 38 68 20 + 38 70 10 + 35 66 10 + 35 69 10 + 25 85 20 + 22 75 30 + 22 85 10 + 20 80 40 + 20 85 40 + 18 75 20 + 15 75 20 + 15 80 10 + 30 50 10 + 30 52 20 + 28 52 20 + 28 55 10 + 25 50 10 + 25 52 40 + 25 55 10 + 23 52 10 + 23 55 20 + 20 50 10 + 20 55 10 + 10 35 20 + 10 40 30 + 8 40 40 + 8 45 20 + 5 35 10 + 5 45 10 + 2 40 20 + 0 40 30 + 0 45 20 + 35 30 10 + 35 32 10 + 33 32 20 + 33 35 10 + 32 30 10 + 30 30 10 + 30 32 30 + 30 35 10 + 28 30 10 + 28 35 10 + 26 32 10 + 25 30 10 + 25 35 10 + 44 5 20 + 42 10 40 + 42 15 10 + 40 5 30 + 40 15 40 + 38 5 30 + 38 15 10 + 35 5 20 + 50 30 10 + 50 35 20 + 50 40 50 + 48 30 10 + 48 40 10 + 47 35 10 + 47 40 10 + 45 30 10 + 45 35 10 + 95 30 30 + 95 35 20 + 53 30 10 + 92 30 10 + 53 35 50 + 45 65 20 + 90 35 10 + 88 30 10 + 88 35 20 + 87 30 10 + 85 25 10 + 85 35 30 + 75 55 20 + 72 55 10 + 70 58 20 + 68 60 30 + 66 55 10 + 65 55 20 + 65 60 30 + 63 58 10 + 60 55 10 + 60 60 10 + 67 85 20 + 65 85 40 + 65 82 10 + 62 80 30 + 60 80 10 + 60 85 30 + 58 75 20 + 55 80 10 + 55 85 20 diff --git a/jsprit-instances/instances/christofides/vrpnc2.txt b/jsprit-instances/instances/christofides/vrpnc2.txt new file mode 100644 index 00000000..8bf69c00 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc2.txt @@ -0,0 +1,77 @@ + 75 140 999999 0 + 40 40 + 22 22 18 + 36 26 26 + 21 45 11 + 45 35 30 + 55 20 21 + 33 34 19 + 50 50 15 + 55 45 16 + 26 59 29 + 40 66 26 + 55 65 37 + 35 51 16 + 62 35 12 + 62 57 31 + 62 24 8 + 21 36 19 + 33 44 20 + 9 56 13 + 62 48 15 + 66 14 22 + 44 13 28 + 26 13 12 + 11 28 6 + 7 43 27 + 17 64 14 + 41 46 18 + 55 34 17 + 35 16 29 + 52 26 13 + 43 26 22 + 31 76 25 + 22 53 28 + 26 29 27 + 50 40 19 + 55 50 10 + 54 10 12 + 60 15 14 + 47 66 24 + 30 60 16 + 30 50 33 + 12 17 15 + 15 14 11 + 16 19 18 + 21 48 17 + 50 30 21 + 51 42 27 + 50 15 19 + 48 21 20 + 12 38 5 + 15 56 22 + 29 39 12 + 54 38 19 + 55 57 22 + 67 41 16 + 10 70 7 + 6 25 26 + 65 27 14 + 40 60 21 + 70 64 24 + 64 4 13 + 36 6 15 + 30 20 18 + 20 30 11 + 15 5 28 + 50 70 9 + 57 72 37 + 45 42 30 + 38 33 10 + 50 4 8 + 66 8 11 + 59 5 3 + 35 60 1 + 27 24 6 + 40 20 10 + 40 37 20 diff --git a/jsprit-instances/instances/christofides/vrpnc3.txt b/jsprit-instances/instances/christofides/vrpnc3.txt new file mode 100644 index 00000000..f91ff981 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc3.txt @@ -0,0 +1,102 @@ + 100 200 999999 0 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 diff --git a/jsprit-instances/instances/christofides/vrpnc4.txt b/jsprit-instances/instances/christofides/vrpnc4.txt new file mode 100644 index 00000000..bd282179 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc4.txt @@ -0,0 +1,152 @@ + 150 200 999999 0 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 diff --git a/jsprit-instances/instances/christofides/vrpnc5.txt b/jsprit-instances/instances/christofides/vrpnc5.txt new file mode 100644 index 00000000..ba2e719e --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc5.txt @@ -0,0 +1,201 @@ + 199 200 999999 0 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 + 22 22 18 + 36 26 26 + 21 45 11 + 45 35 30 + 55 20 21 + 33 34 19 + 50 50 15 + 55 45 16 + 26 59 29 + 40 66 26 + 55 65 37 + 35 51 16 + 62 35 12 + 62 57 31 + 62 24 8 + 21 36 19 + 33 44 20 + 9 56 13 + 62 48 15 + 66 14 22 + 44 13 28 + 26 13 12 + 11 28 6 + 7 43 27 + 17 64 14 + 41 46 18 + 55 34 17 + 35 16 29 + 52 26 13 + 43 26 22 + 31 76 25 + 22 53 28 + 26 29 27 + 50 40 19 + 55 50 10 + 54 10 12 + 60 15 14 + 47 66 24 + 30 60 16 + 30 50 33 + 12 17 15 + 15 14 11 + 16 19 18 + 21 48 17 + 50 30 21 + 51 42 27 + 50 15 19 + 48 21 20 + 12 38 5 diff --git a/jsprit-instances/instances/christofides/vrpnc6.txt b/jsprit-instances/instances/christofides/vrpnc6.txt new file mode 100644 index 00000000..6a966b52 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc6.txt @@ -0,0 +1,52 @@ + 50 160 200 10 + 30 40 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 diff --git a/jsprit-instances/instances/christofides/vrpnc7.txt b/jsprit-instances/instances/christofides/vrpnc7.txt new file mode 100644 index 00000000..fa272e81 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc7.txt @@ -0,0 +1,77 @@ + 75 140 160 10 + 40 40 + 22 22 18 + 36 26 26 + 21 45 11 + 45 35 30 + 55 20 21 + 33 34 19 + 50 50 15 + 55 45 16 + 26 59 29 + 40 66 26 + 55 65 37 + 35 51 16 + 62 35 12 + 62 57 31 + 62 24 8 + 21 36 19 + 33 44 20 + 9 56 13 + 62 48 15 + 66 14 22 + 44 13 28 + 26 13 12 + 11 28 6 + 7 43 27 + 17 64 14 + 41 46 18 + 55 34 17 + 35 16 29 + 52 26 13 + 43 26 22 + 31 76 25 + 22 53 28 + 26 29 27 + 50 40 19 + 55 50 10 + 54 10 12 + 60 15 14 + 47 66 24 + 30 60 16 + 30 50 33 + 12 17 15 + 15 14 11 + 16 19 18 + 21 48 17 + 50 30 21 + 51 42 27 + 50 15 19 + 48 21 20 + 12 38 5 + 15 56 22 + 29 39 12 + 54 38 19 + 55 57 22 + 67 41 16 + 10 70 7 + 6 25 26 + 65 27 14 + 40 60 21 + 70 64 24 + 64 4 13 + 36 6 15 + 30 20 18 + 20 30 11 + 15 5 28 + 50 70 9 + 57 72 37 + 45 42 30 + 38 33 10 + 50 4 8 + 66 8 11 + 59 5 3 + 35 60 1 + 27 24 6 + 40 20 10 + 40 37 20 diff --git a/jsprit-instances/instances/christofides/vrpnc8.txt b/jsprit-instances/instances/christofides/vrpnc8.txt new file mode 100644 index 00000000..da1d7887 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc8.txt @@ -0,0 +1,102 @@ + 100 200 230 10 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 diff --git a/jsprit-instances/instances/christofides/vrpnc9.txt b/jsprit-instances/instances/christofides/vrpnc9.txt new file mode 100644 index 00000000..c6ebf9e9 --- /dev/null +++ b/jsprit-instances/instances/christofides/vrpnc9.txt @@ -0,0 +1,152 @@ + 150 200 200 10 + 35 35 + 41 49 10 + 35 17 7 + 55 45 13 + 55 20 19 + 15 30 26 + 25 30 3 + 20 50 5 + 10 43 9 + 55 60 16 + 30 60 16 + 20 65 12 + 50 35 19 + 30 25 23 + 15 10 20 + 30 5 8 + 10 20 19 + 5 30 2 + 20 40 12 + 15 60 17 + 45 65 9 + 45 20 11 + 45 10 18 + 55 5 29 + 65 35 3 + 65 20 6 + 45 30 17 + 35 40 16 + 41 37 16 + 64 42 9 + 40 60 21 + 31 52 27 + 35 69 23 + 53 52 11 + 65 55 14 + 63 65 8 + 2 60 5 + 20 20 8 + 5 5 16 + 60 12 31 + 40 25 9 + 42 7 5 + 24 12 5 + 23 3 7 + 11 14 18 + 6 38 16 + 2 48 1 + 8 56 27 + 13 52 36 + 6 68 30 + 47 47 13 + 49 58 10 + 27 43 9 + 37 31 14 + 57 29 18 + 63 23 2 + 53 12 6 + 32 12 7 + 36 26 18 + 21 24 28 + 17 34 3 + 12 24 13 + 24 58 19 + 27 69 10 + 15 77 9 + 62 77 20 + 49 73 25 + 67 5 25 + 56 39 36 + 37 47 6 + 37 56 5 + 57 68 15 + 47 16 25 + 44 17 9 + 46 13 8 + 49 11 18 + 49 42 13 + 53 43 14 + 61 52 3 + 57 48 23 + 56 37 6 + 55 54 26 + 15 47 16 + 14 37 11 + 11 31 7 + 16 22 41 + 4 18 35 + 28 18 26 + 26 52 9 + 26 35 15 + 31 67 3 + 15 19 1 + 22 22 2 + 18 24 22 + 26 27 27 + 25 24 20 + 22 27 11 + 25 21 12 + 19 21 10 + 20 26 9 + 18 18 17 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 diff --git a/jsprit-instances/instances/cordeau/p01 b/jsprit-instances/instances/cordeau/p01 new file mode 100644 index 00000000..59157571 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p01 @@ -0,0 +1,59 @@ +2 4 50 4 +0 80 +0 80 +0 80 +0 80 + 1 37 52 0 7 1 4 1 2 4 8 + 2 49 49 0 30 1 4 1 2 4 8 + 3 52 64 0 16 1 4 1 2 4 8 + 4 20 26 0 9 1 4 1 2 4 8 + 5 40 30 0 21 1 4 1 2 4 8 + 6 21 47 0 15 1 4 1 2 4 8 + 7 17 63 0 19 1 4 1 2 4 8 + 8 31 62 0 23 1 4 1 2 4 8 + 9 52 33 0 11 1 4 1 2 4 8 +10 51 21 0 5 1 4 1 2 4 8 +11 42 41 0 19 1 4 1 2 4 8 +12 31 32 0 29 1 4 1 2 4 8 +13 5 25 0 23 1 4 1 2 4 8 +14 12 42 0 21 1 4 1 2 4 8 +15 36 16 0 10 1 4 1 2 4 8 +16 52 41 0 15 1 4 1 2 4 8 +17 27 23 0 3 1 4 1 2 4 8 +18 17 33 0 41 1 4 1 2 4 8 +19 13 13 0 9 1 4 1 2 4 8 +20 57 58 0 28 1 4 1 2 4 8 +21 62 42 0 8 1 4 1 2 4 8 +22 42 57 0 8 1 4 1 2 4 8 +23 16 57 0 16 1 4 1 2 4 8 +24 8 52 0 10 1 4 1 2 4 8 +25 7 38 0 28 1 4 1 2 4 8 +26 27 68 0 7 1 4 1 2 4 8 +27 30 48 0 15 1 4 1 2 4 8 +28 43 67 0 14 1 4 1 2 4 8 +29 58 48 0 6 1 4 1 2 4 8 +30 58 27 0 19 1 4 1 2 4 8 +31 37 69 0 11 1 4 1 2 4 8 +32 38 46 0 12 1 4 1 2 4 8 +33 46 10 0 23 1 4 1 2 4 8 +34 61 33 0 26 1 4 1 2 4 8 +35 62 63 0 17 1 4 1 2 4 8 +36 63 69 0 6 1 4 1 2 4 8 +37 32 22 0 9 1 4 1 2 4 8 +38 45 35 0 15 1 4 1 2 4 8 +39 59 15 0 14 1 4 1 2 4 8 +40 5 6 0 7 1 4 1 2 4 8 +41 10 17 0 27 1 4 1 2 4 8 +42 21 10 0 13 1 4 1 2 4 8 +43 5 64 0 11 1 4 1 2 4 8 +44 30 15 0 16 1 4 1 2 4 8 +45 39 10 0 10 1 4 1 2 4 8 +46 32 39 0 5 1 4 1 2 4 8 +47 25 32 0 25 1 4 1 2 4 8 +48 25 55 0 17 1 4 1 2 4 8 +49 48 28 0 18 1 4 1 2 4 8 +50 56 37 0 10 1 4 1 2 4 8 +51 20 20 0 0 0 0 +52 30 40 0 0 0 0 +53 50 30 0 0 0 0 +54 60 50 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p01.res b/jsprit-instances/instances/cordeau/p01.res new file mode 100644 index 00000000..2f8dccaa --- /dev/null +++ b/jsprit-instances/instances/cordeau/p01.res @@ -0,0 +1,12 @@ +576.87 +1 1 60.06 71 0 44 45 33 15 37 17 0 +1 2 66.55 79 0 42 19 40 41 13 0 +1 3 47.00 78 0 25 18 4 0 +2 1 53.44 73 0 6 27 1 32 11 46 0 +2 2 79.47 80 0 48 8 26 31 28 22 0 +2 3 81.40 77 0 23 7 43 24 14 0 +2 4 23.50 54 0 12 47 0 +3 1 50.41 75 0 9 34 30 39 10 0 +3 2 25.22 54 0 49 5 38 0 +4 1 47.67 67 0 35 36 3 20 0 +4 2 42.14 69 0 21 50 16 2 29 0 diff --git a/jsprit-instances/instances/cordeau/p02 b/jsprit-instances/instances/cordeau/p02 new file mode 100644 index 00000000..bae8caf3 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p02 @@ -0,0 +1,59 @@ +2 2 50 4 +0 160 +0 160 +0 160 +0 160 + 1 37 52 0 7 1 4 1 2 4 8 + 2 49 49 0 30 1 4 1 2 4 8 + 3 52 64 0 16 1 4 1 2 4 8 + 4 20 26 0 9 1 4 1 2 4 8 + 5 40 30 0 21 1 4 1 2 4 8 + 6 21 47 0 15 1 4 1 2 4 8 + 7 17 63 0 19 1 4 1 2 4 8 + 8 31 62 0 23 1 4 1 2 4 8 + 9 52 33 0 11 1 4 1 2 4 8 +10 51 21 0 5 1 4 1 2 4 8 +11 42 41 0 19 1 4 1 2 4 8 +12 31 32 0 29 1 4 1 2 4 8 +13 5 25 0 23 1 4 1 2 4 8 +14 12 42 0 21 1 4 1 2 4 8 +15 36 16 0 10 1 4 1 2 4 8 +16 52 41 0 15 1 4 1 2 4 8 +17 27 23 0 3 1 4 1 2 4 8 +18 17 33 0 41 1 4 1 2 4 8 +19 13 13 0 9 1 4 1 2 4 8 +20 57 58 0 28 1 4 1 2 4 8 +21 62 42 0 8 1 4 1 2 4 8 +22 42 57 0 8 1 4 1 2 4 8 +23 16 57 0 16 1 4 1 2 4 8 +24 8 52 0 10 1 4 1 2 4 8 +25 7 38 0 28 1 4 1 2 4 8 +26 27 68 0 7 1 4 1 2 4 8 +27 30 48 0 15 1 4 1 2 4 8 +28 43 67 0 14 1 4 1 2 4 8 +29 58 48 0 6 1 4 1 2 4 8 +30 58 27 0 19 1 4 1 2 4 8 +31 37 69 0 11 1 4 1 2 4 8 +32 38 46 0 12 1 4 1 2 4 8 +33 46 10 0 23 1 4 1 2 4 8 +34 61 33 0 26 1 4 1 2 4 8 +35 62 63 0 17 1 4 1 2 4 8 +36 63 69 0 6 1 4 1 2 4 8 +37 32 22 0 9 1 4 1 2 4 8 +38 45 35 0 15 1 4 1 2 4 8 +39 59 15 0 14 1 4 1 2 4 8 +40 5 6 0 7 1 4 1 2 4 8 +41 10 17 0 27 1 4 1 2 4 8 +42 21 10 0 13 1 4 1 2 4 8 +43 5 64 0 11 1 4 1 2 4 8 +44 30 15 0 16 1 4 1 2 4 8 +45 39 10 0 10 1 4 1 2 4 8 +46 32 39 0 5 1 4 1 2 4 8 +47 25 32 0 25 1 4 1 2 4 8 +48 25 55 0 17 1 4 1 2 4 8 +49 48 28 0 18 1 4 1 2 4 8 +50 56 37 0 10 1 4 1 2 4 8 +51 20 20 0 0 0 0 +52 30 40 0 0 0 0 +53 50 30 0 0 0 0 +54 60 50 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p02.res b/jsprit-instances/instances/cordeau/p02.res new file mode 100644 index 00000000..b60ef0fd --- /dev/null +++ b/jsprit-instances/instances/cordeau/p02.res @@ -0,0 +1,6 @@ +473.53 +1 1 87.04 154 0 4 47 18 13 41 40 19 42 0 +2 1 101.91 157 0 6 14 25 24 43 7 23 48 27 46 0 +3 1 74.27 153 0 38 11 2 16 50 21 34 30 9 0 +3 2 95.30 158 0 10 39 33 45 15 44 37 17 12 5 49 0 +4 1 115.02 155 0 20 35 36 3 28 31 26 8 22 1 32 29 0 diff --git a/jsprit-instances/instances/cordeau/p03 b/jsprit-instances/instances/cordeau/p03 new file mode 100644 index 00000000..2edaf1dc --- /dev/null +++ b/jsprit-instances/instances/cordeau/p03 @@ -0,0 +1,86 @@ +2 3 75 5 +0 140 +0 140 +0 140 +0 140 +0 140 + 1 22 22 0 18 1 5 1 2 4 8 16 + 2 36 26 0 26 1 5 1 2 4 8 16 + 3 21 45 0 11 1 5 1 2 4 8 16 + 4 45 35 0 30 1 5 1 2 4 8 16 + 5 55 20 0 21 1 5 1 2 4 8 16 + 6 33 34 0 19 1 5 1 2 4 8 16 + 7 50 50 0 15 1 5 1 2 4 8 16 + 8 55 45 0 16 1 5 1 2 4 8 16 + 9 26 59 0 29 1 5 1 2 4 8 16 +10 40 66 0 26 1 5 1 2 4 8 16 +11 55 65 0 37 1 5 1 2 4 8 16 +12 35 51 0 16 1 5 1 2 4 8 16 +13 62 35 0 12 1 5 1 2 4 8 16 +14 62 57 0 31 1 5 1 2 4 8 16 +15 62 24 0 8 1 5 1 2 4 8 16 +16 21 36 0 19 1 5 1 2 4 8 16 +17 33 44 0 20 1 5 1 2 4 8 16 +18 9 56 0 13 1 5 1 2 4 8 16 +19 62 48 0 15 1 5 1 2 4 8 16 +20 66 14 0 22 1 5 1 2 4 8 16 +21 44 13 0 28 1 5 1 2 4 8 16 +22 26 13 0 12 1 5 1 2 4 8 16 +23 11 28 0 6 1 5 1 2 4 8 16 +24 7 43 0 27 1 5 1 2 4 8 16 +25 17 64 0 14 1 5 1 2 4 8 16 +26 41 46 0 18 1 5 1 2 4 8 16 +27 55 34 0 17 1 5 1 2 4 8 16 +28 35 16 0 29 1 5 1 2 4 8 16 +29 52 26 0 13 1 5 1 2 4 8 16 +30 43 26 0 22 1 5 1 2 4 8 16 +31 31 76 0 25 1 5 1 2 4 8 16 +32 22 53 0 28 1 5 1 2 4 8 16 +33 26 29 0 27 1 5 1 2 4 8 16 +34 50 40 0 19 1 5 1 2 4 8 16 +35 55 50 0 10 1 5 1 2 4 8 16 +36 54 10 0 12 1 5 1 2 4 8 16 +37 60 15 0 14 1 5 1 2 4 8 16 +38 47 66 0 24 1 5 1 2 4 8 16 +39 30 60 0 16 1 5 1 2 4 8 16 +40 30 50 0 33 1 5 1 2 4 8 16 +41 12 17 0 15 1 5 1 2 4 8 16 +42 15 14 0 11 1 5 1 2 4 8 16 +43 16 19 0 18 1 5 1 2 4 8 16 +44 21 48 0 17 1 5 1 2 4 8 16 +45 50 30 0 21 1 5 1 2 4 8 16 +46 51 42 0 27 1 5 1 2 4 8 16 +47 50 15 0 19 1 5 1 2 4 8 16 +48 48 21 0 20 1 5 1 2 4 8 16 +49 12 38 0 5 1 5 1 2 4 8 16 +50 15 56 0 22 1 5 1 2 4 8 16 +51 29 39 0 12 1 5 1 2 4 8 16 +52 54 38 0 19 1 5 1 2 4 8 16 +53 55 57 0 22 1 5 1 2 4 8 16 +54 67 41 0 16 1 5 1 2 4 8 16 +55 10 70 0 7 1 5 1 2 4 8 16 +56 6 25 0 26 1 5 1 2 4 8 16 +57 65 27 0 14 1 5 1 2 4 8 16 +58 40 60 0 21 1 5 1 2 4 8 16 +59 70 64 0 24 1 5 1 2 4 8 16 +60 64 4 0 13 1 5 1 2 4 8 16 +61 36 6 0 15 1 5 1 2 4 8 16 +62 30 20 0 18 1 5 1 2 4 8 16 +63 20 30 0 11 1 5 1 2 4 8 16 +64 15 5 0 28 1 5 1 2 4 8 16 +65 50 70 0 9 1 5 1 2 4 8 16 +66 57 72 0 37 1 5 1 2 4 8 16 +67 45 42 0 30 1 5 1 2 4 8 16 +68 38 33 0 10 1 5 1 2 4 8 16 +69 50 4 0 8 1 5 1 2 4 8 16 +70 66 8 0 11 1 5 1 2 4 8 16 +71 59 5 0 3 1 5 1 2 4 8 16 +72 35 60 0 1 1 5 1 2 4 8 16 +73 27 24 0 6 1 5 1 2 4 8 16 +74 40 20 0 10 1 5 1 2 4 8 16 +75 40 37 0 20 1 5 1 2 4 8 16 +76 40 40 0 0 0 0 +77 50 22 0 0 0 0 +78 55 55 0 0 0 0 +79 25 45 0 0 0 0 +80 20 20 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p03.res b/jsprit-instances/instances/cordeau/p03.res new file mode 100644 index 00000000..29807885 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p03.res @@ -0,0 +1,12 @@ +641.19 +1 1 27.76 106 0 4 34 46 67 0 +1 2 39.71 99 0 26 17 51 6 68 75 0 +2 1 63.78 123 0 5 37 20 70 60 71 69 36 47 0 +2 2 50.46 140 0 48 21 74 2 30 45 29 0 +3 1 72.50 127 0 35 8 52 27 15 57 13 54 19 0 +3 2 57.53 138 0 14 59 66 65 11 0 +3 3 77.20 134 0 7 58 72 31 10 38 53 0 +4 1 42.34 122 0 40 12 39 9 32 0 +4 2 87.79 135 0 3 44 50 25 55 18 24 49 16 0 +5 1 53.04 127 0 43 41 56 23 63 33 73 1 0 +5 2 69.07 113 0 62 28 61 22 64 42 0 diff --git a/jsprit-instances/instances/cordeau/p04 b/jsprit-instances/instances/cordeau/p04 new file mode 100644 index 00000000..e1cd4094 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p04 @@ -0,0 +1,105 @@ +2 8 100 2 +0 100 +0 100 + 1 41 49 0 10 1 2 1 2 + 2 35 17 0 7 1 2 1 2 + 3 55 45 0 13 1 2 1 2 + 4 55 20 0 19 1 2 1 2 + 5 15 30 0 26 1 2 1 2 + 6 25 30 0 3 1 2 1 2 + 7 20 50 0 5 1 2 1 2 + 8 10 43 0 9 1 2 1 2 + 9 55 60 0 16 1 2 1 2 + 10 30 60 0 16 1 2 1 2 + 11 20 65 0 12 1 2 1 2 + 12 50 35 0 19 1 2 1 2 + 13 30 25 0 23 1 2 1 2 + 14 15 10 0 20 1 2 1 2 + 15 30 5 0 8 1 2 1 2 + 16 10 20 0 19 1 2 1 2 + 17 5 30 0 2 1 2 1 2 + 18 20 40 0 12 1 2 1 2 + 19 15 60 0 17 1 2 1 2 + 20 45 65 0 9 1 2 1 2 + 21 45 20 0 11 1 2 1 2 + 22 45 10 0 18 1 2 1 2 + 23 55 5 0 29 1 2 1 2 + 24 65 35 0 3 1 2 1 2 + 25 65 20 0 6 1 2 1 2 + 26 45 30 0 17 1 2 1 2 + 27 35 40 0 16 1 2 1 2 + 28 41 37 0 16 1 2 1 2 + 29 64 42 0 9 1 2 1 2 + 30 40 60 0 21 1 2 1 2 + 31 31 52 0 27 1 2 1 2 + 32 35 69 0 23 1 2 1 2 + 33 53 52 0 11 1 2 1 2 + 34 65 55 0 14 1 2 1 2 + 35 63 65 0 8 1 2 1 2 + 36 2 60 0 5 1 2 1 2 + 37 20 20 0 8 1 2 1 2 + 38 5 5 0 16 1 2 1 2 + 39 60 12 0 31 1 2 1 2 + 40 40 25 0 9 1 2 1 2 + 41 42 7 0 5 1 2 1 2 + 42 24 12 0 5 1 2 1 2 + 43 23 3 0 7 1 2 1 2 + 44 11 14 0 18 1 2 1 2 + 45 6 38 0 16 1 2 1 2 + 46 2 48 0 1 1 2 1 2 + 47 8 56 0 27 1 2 1 2 + 48 13 52 0 36 1 2 1 2 + 49 6 68 0 30 1 2 1 2 + 50 47 47 0 13 1 2 1 2 + 51 49 58 0 10 1 2 1 2 + 52 27 43 0 9 1 2 1 2 + 53 37 31 0 14 1 2 1 2 + 54 57 29 0 18 1 2 1 2 + 55 63 23 0 2 1 2 1 2 + 56 53 12 0 6 1 2 1 2 + 57 32 12 0 7 1 2 1 2 + 58 36 26 0 18 1 2 1 2 + 59 21 24 0 28 1 2 1 2 + 60 17 34 0 3 1 2 1 2 + 61 12 24 0 13 1 2 1 2 + 62 24 58 0 19 1 2 1 2 + 63 27 69 0 10 1 2 1 2 + 64 15 77 0 9 1 2 1 2 + 65 62 77 0 20 1 2 1 2 + 66 49 73 0 25 1 2 1 2 + 67 67 5 0 25 1 2 1 2 + 68 56 39 0 36 1 2 1 2 + 69 37 47 0 6 1 2 1 2 + 70 37 56 0 5 1 2 1 2 + 71 57 68 0 15 1 2 1 2 + 72 47 16 0 25 1 2 1 2 + 73 44 17 0 9 1 2 1 2 + 74 46 13 0 8 1 2 1 2 + 75 49 11 0 18 1 2 1 2 + 76 49 42 0 13 1 2 1 2 + 77 53 43 0 14 1 2 1 2 + 78 61 52 0 3 1 2 1 2 + 79 57 48 0 23 1 2 1 2 + 80 56 37 0 6 1 2 1 2 + 81 55 54 0 26 1 2 1 2 + 82 15 47 0 16 1 2 1 2 + 83 14 37 0 11 1 2 1 2 + 84 11 31 0 7 1 2 1 2 + 85 16 22 0 41 1 2 1 2 + 86 4 18 0 35 1 2 1 2 + 87 28 18 0 26 1 2 1 2 + 88 26 52 0 9 1 2 1 2 + 89 26 35 0 15 1 2 1 2 + 90 31 67 0 3 1 2 1 2 + 91 15 19 0 1 1 2 1 2 + 92 22 22 0 2 1 2 1 2 + 93 18 24 0 22 1 2 1 2 + 94 26 27 0 27 1 2 1 2 + 95 25 24 0 20 1 2 1 2 + 96 22 27 0 11 1 2 1 2 + 97 25 21 0 12 1 2 1 2 + 98 19 21 0 10 1 2 1 2 + 99 20 26 0 9 1 2 1 2 +100 18 18 0 17 1 2 1 2 +101 35 20 0 0 0 0 +102 35 50 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p04.res b/jsprit-instances/instances/cordeau/p04.res new file mode 100644 index 00000000..99eeeb71 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p04.res @@ -0,0 +1,16 @@ +1001.59 +1 1 76.51 96 0 41 23 67 39 56 0 +1 2 59.50 93 0 96 6 89 27 28 53 58 0 +1 3 88.39 100 0 92 61 16 86 38 43 15 0 +1 4 60.71 98 0 57 42 14 44 91 100 98 37 97 0 +1 5 40.57 87 0 21 72 74 75 22 2 0 +1 6 73.41 99 0 73 4 25 55 54 12 26 40 0 +1 7 41.56 100 0 59 99 93 85 0 +1 8 28.69 96 0 87 95 94 13 0 +2 1 74.12 100 0 69 76 77 68 80 24 29 3 0 +2 2 89.62 99 0 51 9 35 71 65 66 70 0 +2 3 84.30 95 0 8 45 17 84 5 60 83 18 52 0 +2 4 107.18 98 0 63 64 49 36 47 46 82 0 +2 5 64.10 100 0 33 81 34 78 79 50 1 0 +2 6 59.81 98 0 88 7 48 19 11 62 0 +2 7 53.10 99 0 31 10 90 32 20 30 0 diff --git a/jsprit-instances/instances/cordeau/p05 b/jsprit-instances/instances/cordeau/p05 new file mode 100644 index 00000000..c9900fcf --- /dev/null +++ b/jsprit-instances/instances/cordeau/p05 @@ -0,0 +1,105 @@ +2 5 100 2 +0 200 +0 200 + 1 41 49 0 10 1 2 1 2 + 2 35 17 0 7 1 2 1 2 + 3 55 45 0 13 1 2 1 2 + 4 55 20 0 19 1 2 1 2 + 5 15 30 0 26 1 2 1 2 + 6 25 30 0 3 1 2 1 2 + 7 20 50 0 5 1 2 1 2 + 8 10 43 0 9 1 2 1 2 + 9 55 60 0 16 1 2 1 2 + 10 30 60 0 16 1 2 1 2 + 11 20 65 0 12 1 2 1 2 + 12 50 35 0 19 1 2 1 2 + 13 30 25 0 23 1 2 1 2 + 14 15 10 0 20 1 2 1 2 + 15 30 5 0 8 1 2 1 2 + 16 10 20 0 19 1 2 1 2 + 17 5 30 0 2 1 2 1 2 + 18 20 40 0 12 1 2 1 2 + 19 15 60 0 17 1 2 1 2 + 20 45 65 0 9 1 2 1 2 + 21 45 20 0 11 1 2 1 2 + 22 45 10 0 18 1 2 1 2 + 23 55 5 0 29 1 2 1 2 + 24 65 35 0 3 1 2 1 2 + 25 65 20 0 6 1 2 1 2 + 26 45 30 0 17 1 2 1 2 + 27 35 40 0 16 1 2 1 2 + 28 41 37 0 16 1 2 1 2 + 29 64 42 0 9 1 2 1 2 + 30 40 60 0 21 1 2 1 2 + 31 31 52 0 27 1 2 1 2 + 32 35 69 0 23 1 2 1 2 + 33 53 52 0 11 1 2 1 2 + 34 65 55 0 14 1 2 1 2 + 35 63 65 0 8 1 2 1 2 + 36 2 60 0 5 1 2 1 2 + 37 20 20 0 8 1 2 1 2 + 38 5 5 0 16 1 2 1 2 + 39 60 12 0 31 1 2 1 2 + 40 40 25 0 9 1 2 1 2 + 41 42 7 0 5 1 2 1 2 + 42 24 12 0 5 1 2 1 2 + 43 23 3 0 7 1 2 1 2 + 44 11 14 0 18 1 2 1 2 + 45 6 38 0 16 1 2 1 2 + 46 2 48 0 1 1 2 1 2 + 47 8 56 0 27 1 2 1 2 + 48 13 52 0 36 1 2 1 2 + 49 6 68 0 30 1 2 1 2 + 50 47 47 0 13 1 2 1 2 + 51 49 58 0 10 1 2 1 2 + 52 27 43 0 9 1 2 1 2 + 53 37 31 0 14 1 2 1 2 + 54 57 29 0 18 1 2 1 2 + 55 63 23 0 2 1 2 1 2 + 56 53 12 0 6 1 2 1 2 + 57 32 12 0 7 1 2 1 2 + 58 36 26 0 18 1 2 1 2 + 59 21 24 0 28 1 2 1 2 + 60 17 34 0 3 1 2 1 2 + 61 12 24 0 13 1 2 1 2 + 62 24 58 0 19 1 2 1 2 + 63 27 69 0 10 1 2 1 2 + 64 15 77 0 9 1 2 1 2 + 65 62 77 0 20 1 2 1 2 + 66 49 73 0 25 1 2 1 2 + 67 67 5 0 25 1 2 1 2 + 68 56 39 0 36 1 2 1 2 + 69 37 47 0 6 1 2 1 2 + 70 37 56 0 5 1 2 1 2 + 71 57 68 0 15 1 2 1 2 + 72 47 16 0 25 1 2 1 2 + 73 44 17 0 9 1 2 1 2 + 74 46 13 0 8 1 2 1 2 + 75 49 11 0 18 1 2 1 2 + 76 49 42 0 13 1 2 1 2 + 77 53 43 0 14 1 2 1 2 + 78 61 52 0 3 1 2 1 2 + 79 57 48 0 23 1 2 1 2 + 80 56 37 0 6 1 2 1 2 + 81 55 54 0 26 1 2 1 2 + 82 15 47 0 16 1 2 1 2 + 83 14 37 0 11 1 2 1 2 + 84 11 31 0 7 1 2 1 2 + 85 16 22 0 41 1 2 1 2 + 86 4 18 0 35 1 2 1 2 + 87 28 18 0 26 1 2 1 2 + 88 26 52 0 9 1 2 1 2 + 89 26 35 0 15 1 2 1 2 + 90 31 67 0 3 1 2 1 2 + 91 15 19 0 1 1 2 1 2 + 92 22 22 0 2 1 2 1 2 + 93 18 24 0 22 1 2 1 2 + 94 26 27 0 27 1 2 1 2 + 95 25 24 0 20 1 2 1 2 + 96 22 27 0 11 1 2 1 2 + 97 25 21 0 12 1 2 1 2 + 98 19 21 0 10 1 2 1 2 + 99 20 26 0 9 1 2 1 2 +100 18 18 0 17 1 2 1 2 +101 15 35 0 0 0 0 +102 55 35 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p05.res b/jsprit-instances/instances/cordeau/p05.res new file mode 100644 index 00000000..71feb7a2 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p05.res @@ -0,0 +1,9 @@ +750.03 +1 1 138.91 197 0 89 27 69 1 70 30 32 90 63 64 49 36 47 46 45 0 +1 2 60.16 195 0 60 6 94 13 95 97 92 37 100 98 93 59 99 96 0 +1 3 94.91 198 0 18 52 7 88 31 10 62 11 19 48 82 8 83 0 +1 4 84.18 198 0 5 61 85 91 16 44 14 38 86 17 84 0 +2 1 127.89 195 0 76 50 33 81 9 51 20 66 65 71 35 34 78 29 24 0 +2 2 27.97 92 0 77 3 79 68 80 0 +2 3 124.14 196 0 12 28 53 58 2 57 87 42 43 15 41 22 73 21 40 26 0 +2 4 91.86 187 0 4 72 74 75 56 23 67 39 25 55 54 0 diff --git a/jsprit-instances/instances/cordeau/p06 b/jsprit-instances/instances/cordeau/p06 new file mode 100644 index 00000000..37520fda --- /dev/null +++ b/jsprit-instances/instances/cordeau/p06 @@ -0,0 +1,107 @@ +2 6 100 3 +0 100 +0 100 +0 100 + 1 41 49 0 10 1 3 1 2 4 + 2 35 17 0 7 1 3 1 2 4 + 3 55 45 0 13 1 3 1 2 4 + 4 55 20 0 19 1 3 1 2 4 + 5 15 30 0 26 1 3 1 2 4 + 6 25 30 0 3 1 3 1 2 4 + 7 20 50 0 5 1 3 1 2 4 + 8 10 43 0 9 1 3 1 2 4 + 9 55 60 0 16 1 3 1 2 4 + 10 30 60 0 16 1 3 1 2 4 + 11 20 65 0 12 1 3 1 2 4 + 12 50 35 0 19 1 3 1 2 4 + 13 30 25 0 23 1 3 1 2 4 + 14 15 10 0 20 1 3 1 2 4 + 15 30 5 0 8 1 3 1 2 4 + 16 10 20 0 19 1 3 1 2 4 + 17 5 30 0 2 1 3 1 2 4 + 18 20 40 0 12 1 3 1 2 4 + 19 15 60 0 17 1 3 1 2 4 + 20 45 65 0 9 1 3 1 2 4 + 21 45 20 0 11 1 3 1 2 4 + 22 45 10 0 18 1 3 1 2 4 + 23 55 5 0 29 1 3 1 2 4 + 24 65 35 0 3 1 3 1 2 4 + 25 65 20 0 6 1 3 1 2 4 + 26 45 30 0 17 1 3 1 2 4 + 27 35 40 0 16 1 3 1 2 4 + 28 41 37 0 16 1 3 1 2 4 + 29 64 42 0 9 1 3 1 2 4 + 30 40 60 0 21 1 3 1 2 4 + 31 31 52 0 27 1 3 1 2 4 + 32 35 69 0 23 1 3 1 2 4 + 33 53 52 0 11 1 3 1 2 4 + 34 65 55 0 14 1 3 1 2 4 + 35 63 65 0 8 1 3 1 2 4 + 36 2 60 0 5 1 3 1 2 4 + 37 20 20 0 8 1 3 1 2 4 + 38 5 5 0 16 1 3 1 2 4 + 39 60 12 0 31 1 3 1 2 4 + 40 40 25 0 9 1 3 1 2 4 + 41 42 7 0 5 1 3 1 2 4 + 42 24 12 0 5 1 3 1 2 4 + 43 23 3 0 7 1 3 1 2 4 + 44 11 14 0 18 1 3 1 2 4 + 45 6 38 0 16 1 3 1 2 4 + 46 2 48 0 1 1 3 1 2 4 + 47 8 56 0 27 1 3 1 2 4 + 48 13 52 0 36 1 3 1 2 4 + 49 6 68 0 30 1 3 1 2 4 + 50 47 47 0 13 1 3 1 2 4 + 51 49 58 0 10 1 3 1 2 4 + 52 27 43 0 9 1 3 1 2 4 + 53 37 31 0 14 1 3 1 2 4 + 54 57 29 0 18 1 3 1 2 4 + 55 63 23 0 2 1 3 1 2 4 + 56 53 12 0 6 1 3 1 2 4 + 57 32 12 0 7 1 3 1 2 4 + 58 36 26 0 18 1 3 1 2 4 + 59 21 24 0 28 1 3 1 2 4 + 60 17 34 0 3 1 3 1 2 4 + 61 12 24 0 13 1 3 1 2 4 + 62 24 58 0 19 1 3 1 2 4 + 63 27 69 0 10 1 3 1 2 4 + 64 15 77 0 9 1 3 1 2 4 + 65 62 77 0 20 1 3 1 2 4 + 66 49 73 0 25 1 3 1 2 4 + 67 67 5 0 25 1 3 1 2 4 + 68 56 39 0 36 1 3 1 2 4 + 69 37 47 0 6 1 3 1 2 4 + 70 37 56 0 5 1 3 1 2 4 + 71 57 68 0 15 1 3 1 2 4 + 72 47 16 0 25 1 3 1 2 4 + 73 44 17 0 9 1 3 1 2 4 + 74 46 13 0 8 1 3 1 2 4 + 75 49 11 0 18 1 3 1 2 4 + 76 49 42 0 13 1 3 1 2 4 + 77 53 43 0 14 1 3 1 2 4 + 78 61 52 0 3 1 3 1 2 4 + 79 57 48 0 23 1 3 1 2 4 + 80 56 37 0 6 1 3 1 2 4 + 81 55 54 0 26 1 3 1 2 4 + 82 15 47 0 16 1 3 1 2 4 + 83 14 37 0 11 1 3 1 2 4 + 84 11 31 0 7 1 3 1 2 4 + 85 16 22 0 41 1 3 1 2 4 + 86 4 18 0 35 1 3 1 2 4 + 87 28 18 0 26 1 3 1 2 4 + 88 26 52 0 9 1 3 1 2 4 + 89 26 35 0 15 1 3 1 2 4 + 90 31 67 0 3 1 3 1 2 4 + 91 15 19 0 1 1 3 1 2 4 + 92 22 22 0 2 1 3 1 2 4 + 93 18 24 0 22 1 3 1 2 4 + 94 26 27 0 27 1 3 1 2 4 + 95 25 24 0 20 1 3 1 2 4 + 96 22 27 0 11 1 3 1 2 4 + 97 25 21 0 12 1 3 1 2 4 + 98 19 21 0 10 1 3 1 2 4 + 99 20 26 0 9 1 3 1 2 4 +100 18 18 0 17 1 3 1 2 4 +101 15 20 0 0 0 0 +102 50 20 0 0 0 0 +103 35 55 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p06.res b/jsprit-instances/instances/cordeau/p06.res new file mode 100644 index 00000000..18ecee7a --- /dev/null +++ b/jsprit-instances/instances/cordeau/p06.res @@ -0,0 +1,17 @@ +876.50 +1 1 4.47 41 0 85 0 +1 2 42.58 89 0 91 44 38 86 16 0 +1 3 18.37 77 0 93 59 98 100 0 +1 4 70.08 100 0 37 97 87 2 57 15 43 42 14 0 +1 5 37.91 95 0 92 95 13 94 6 96 99 0 +1 6 58.55 87 0 5 60 83 8 45 17 84 61 0 +2 1 50.53 91 0 56 23 67 39 0 +2 2 67.85 99 0 54 80 68 29 24 55 25 4 0 +2 3 38.49 94 0 72 75 41 22 74 73 21 0 +2 4 55.08 93 0 26 12 28 53 58 40 0 +3 1 95.71 99 0 51 9 71 65 35 34 78 50 0 +3 2 57.29 99 0 62 19 47 48 0 +3 3 55.18 99 0 70 30 20 66 32 10 0 +3 4 57.06 100 0 33 81 79 3 77 76 0 +3 5 106.54 100 0 88 7 82 46 36 49 64 11 63 90 0 +3 6 60.81 95 0 31 52 18 89 27 69 1 0 diff --git a/jsprit-instances/instances/cordeau/p07 b/jsprit-instances/instances/cordeau/p07 new file mode 100644 index 00000000..bdf2a0be --- /dev/null +++ b/jsprit-instances/instances/cordeau/p07 @@ -0,0 +1,109 @@ +2 4 100 4 +0 100 +0 100 +0 100 +0 100 + 1 41 49 0 10 1 4 1 2 4 8 + 2 35 17 0 7 1 4 1 2 4 8 + 3 55 45 0 13 1 4 1 2 4 8 + 4 55 20 0 19 1 4 1 2 4 8 + 5 15 30 0 26 1 4 1 2 4 8 + 6 25 30 0 3 1 4 1 2 4 8 + 7 20 50 0 5 1 4 1 2 4 8 + 8 10 43 0 9 1 4 1 2 4 8 + 9 55 60 0 16 1 4 1 2 4 8 + 10 30 60 0 16 1 4 1 2 4 8 + 11 20 65 0 12 1 4 1 2 4 8 + 12 50 35 0 19 1 4 1 2 4 8 + 13 30 25 0 23 1 4 1 2 4 8 + 14 15 10 0 20 1 4 1 2 4 8 + 15 30 5 0 8 1 4 1 2 4 8 + 16 10 20 0 19 1 4 1 2 4 8 + 17 5 30 0 2 1 4 1 2 4 8 + 18 20 40 0 12 1 4 1 2 4 8 + 19 15 60 0 17 1 4 1 2 4 8 + 20 45 65 0 9 1 4 1 2 4 8 + 21 45 20 0 11 1 4 1 2 4 8 + 22 45 10 0 18 1 4 1 2 4 8 + 23 55 5 0 29 1 4 1 2 4 8 + 24 65 35 0 3 1 4 1 2 4 8 + 25 65 20 0 6 1 4 1 2 4 8 + 26 45 30 0 17 1 4 1 2 4 8 + 27 35 40 0 16 1 4 1 2 4 8 + 28 41 37 0 16 1 4 1 2 4 8 + 29 64 42 0 9 1 4 1 2 4 8 + 30 40 60 0 21 1 4 1 2 4 8 + 31 31 52 0 27 1 4 1 2 4 8 + 32 35 69 0 23 1 4 1 2 4 8 + 33 53 52 0 11 1 4 1 2 4 8 + 34 65 55 0 14 1 4 1 2 4 8 + 35 63 65 0 8 1 4 1 2 4 8 + 36 2 60 0 5 1 4 1 2 4 8 + 37 20 20 0 8 1 4 1 2 4 8 + 38 5 5 0 16 1 4 1 2 4 8 + 39 60 12 0 31 1 4 1 2 4 8 + 40 40 25 0 9 1 4 1 2 4 8 + 41 42 7 0 5 1 4 1 2 4 8 + 42 24 12 0 5 1 4 1 2 4 8 + 43 23 3 0 7 1 4 1 2 4 8 + 44 11 14 0 18 1 4 1 2 4 8 + 45 6 38 0 16 1 4 1 2 4 8 + 46 2 48 0 1 1 4 1 2 4 8 + 47 8 56 0 27 1 4 1 2 4 8 + 48 13 52 0 36 1 4 1 2 4 8 + 49 6 68 0 30 1 4 1 2 4 8 + 50 47 47 0 13 1 4 1 2 4 8 + 51 49 58 0 10 1 4 1 2 4 8 + 52 27 43 0 9 1 4 1 2 4 8 + 53 37 31 0 14 1 4 1 2 4 8 + 54 57 29 0 18 1 4 1 2 4 8 + 55 63 23 0 2 1 4 1 2 4 8 + 56 53 12 0 6 1 4 1 2 4 8 + 57 32 12 0 7 1 4 1 2 4 8 + 58 36 26 0 18 1 4 1 2 4 8 + 59 21 24 0 28 1 4 1 2 4 8 + 60 17 34 0 3 1 4 1 2 4 8 + 61 12 24 0 13 1 4 1 2 4 8 + 62 24 58 0 19 1 4 1 2 4 8 + 63 27 69 0 10 1 4 1 2 4 8 + 64 15 77 0 9 1 4 1 2 4 8 + 65 62 77 0 20 1 4 1 2 4 8 + 66 49 73 0 25 1 4 1 2 4 8 + 67 67 5 0 25 1 4 1 2 4 8 + 68 56 39 0 36 1 4 1 2 4 8 + 69 37 47 0 6 1 4 1 2 4 8 + 70 37 56 0 5 1 4 1 2 4 8 + 71 57 68 0 15 1 4 1 2 4 8 + 72 47 16 0 25 1 4 1 2 4 8 + 73 44 17 0 9 1 4 1 2 4 8 + 74 46 13 0 8 1 4 1 2 4 8 + 75 49 11 0 18 1 4 1 2 4 8 + 76 49 42 0 13 1 4 1 2 4 8 + 77 53 43 0 14 1 4 1 2 4 8 + 78 61 52 0 3 1 4 1 2 4 8 + 79 57 48 0 23 1 4 1 2 4 8 + 80 56 37 0 6 1 4 1 2 4 8 + 81 55 54 0 26 1 4 1 2 4 8 + 82 15 47 0 16 1 4 1 2 4 8 + 83 14 37 0 11 1 4 1 2 4 8 + 84 11 31 0 7 1 4 1 2 4 8 + 85 16 22 0 41 1 4 1 2 4 8 + 86 4 18 0 35 1 4 1 2 4 8 + 87 28 18 0 26 1 4 1 2 4 8 + 88 26 52 0 9 1 4 1 2 4 8 + 89 26 35 0 15 1 4 1 2 4 8 + 90 31 67 0 3 1 4 1 2 4 8 + 91 15 19 0 1 1 4 1 2 4 8 + 92 22 22 0 2 1 4 1 2 4 8 + 93 18 24 0 22 1 4 1 2 4 8 + 94 26 27 0 27 1 4 1 2 4 8 + 95 25 24 0 20 1 4 1 2 4 8 + 96 22 27 0 11 1 4 1 2 4 8 + 97 25 21 0 12 1 4 1 2 4 8 + 98 19 21 0 10 1 4 1 2 4 8 + 99 20 26 0 9 1 4 1 2 4 8 +100 18 18 0 17 1 4 1 2 4 8 +101 15 35 0 0 0 0 +102 55 35 0 0 0 0 +103 35 20 0 0 0 0 +104 35 50 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p07.res b/jsprit-instances/instances/cordeau/p07.res new file mode 100644 index 00000000..70f5281f --- /dev/null +++ b/jsprit-instances/instances/cordeau/p07.res @@ -0,0 +1,17 @@ +885.80 +1 1 46.39 99 0 82 48 47 8 83 0 +1 2 45.73 95 0 5 61 16 86 17 0 +1 3 39.74 100 0 60 99 37 98 85 93 84 0 +1 4 99.18 95 0 45 46 36 49 64 19 7 18 0 +2 1 51.76 93 0 12 26 40 21 4 54 0 +2 2 60.54 92 0 24 29 34 78 79 3 77 76 0 +2 3 8.36 42 0 68 80 0 +2 4 79.73 99 0 55 25 39 67 23 56 0 +3 1 35.10 99 0 87 97 92 59 96 95 0 +3 2 42.69 100 0 13 94 6 89 53 58 0 +3 3 42.99 90 0 73 72 74 75 22 41 2 0 +3 4 87.38 99 0 42 100 91 44 38 14 43 15 57 0 +4 1 50.80 96 0 70 30 51 81 33 50 1 0 +4 2 43.95 74 0 31 52 27 28 69 0 +4 3 89.37 93 0 9 35 71 65 66 20 0 +4 4 62.09 92 0 10 32 90 63 11 62 88 0 diff --git a/jsprit-instances/instances/cordeau/p08 b/jsprit-instances/instances/cordeau/p08 new file mode 100644 index 00000000..e272d5d8 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p08 @@ -0,0 +1,254 @@ +2 14 249 2 +310 500 +310 500 + 1 -99 -97 0 6 1 2 1 2 + 2 -59 50 0 72 1 2 1 2 + 3 0 14 0 93 1 2 1 2 + 4 -17 -66 0 28 1 2 1 2 + 5 -69 -19 0 5 1 2 1 2 + 6 31 12 0 43 1 2 1 2 + 7 5 -41 0 1 1 2 1 2 + 8 -12 10 0 36 1 2 1 2 + 9 -64 70 0 53 1 2 1 2 + 10 -12 85 0 63 1 2 1 2 + 11 -18 64 0 25 1 2 1 2 + 12 -77 -16 0 50 1 2 1 2 + 13 -53 88 0 57 1 2 1 2 + 14 83 -24 0 1 1 2 1 2 + 15 24 41 0 66 1 2 1 2 + 16 17 21 0 37 1 2 1 2 + 17 42 96 0 51 1 2 1 2 + 18 -65 0 0 47 1 2 1 2 + 19 -47 -26 0 88 1 2 1 2 + 20 85 36 0 75 1 2 1 2 + 21 -35 -54 0 48 1 2 1 2 + 22 54 -21 0 40 1 2 1 2 + 23 64 -17 0 8 1 2 1 2 + 24 55 89 0 69 1 2 1 2 + 25 17 -25 0 93 1 2 1 2 + 26 -61 66 0 29 1 2 1 2 + 27 -61 26 0 5 1 2 1 2 + 28 17 -72 0 53 1 2 1 2 + 29 79 38 0 8 1 2 1 2 + 30 -62 -2 0 24 1 2 1 2 + 31 -90 -68 0 53 1 2 1 2 + 32 52 66 0 13 1 2 1 2 + 33 -54 -50 0 47 1 2 1 2 + 34 8 -84 0 57 1 2 1 2 + 35 37 -90 0 9 1 2 1 2 + 36 -83 49 0 74 1 2 1 2 + 37 35 -1 0 83 1 2 1 2 + 38 7 59 0 96 1 2 1 2 + 39 12 48 0 42 1 2 1 2 + 40 57 95 0 80 1 2 1 2 + 41 92 28 0 22 1 2 1 2 + 42 -3 97 0 56 1 2 1 2 + 43 -7 52 0 43 1 2 1 2 + 44 42 -15 0 12 1 2 1 2 + 45 77 -43 0 73 1 2 1 2 + 46 59 -49 0 32 1 2 1 2 + 47 25 91 0 8 1 2 1 2 + 48 69 -19 0 79 1 2 1 2 + 49 -82 -14 0 79 1 2 1 2 + 50 74 -70 0 4 1 2 1 2 + 51 69 59 0 14 1 2 1 2 + 52 29 33 0 17 1 2 1 2 + 53 -97 9 0 19 1 2 1 2 + 54 -58 9 0 44 1 2 1 2 + 55 28 93 0 5 1 2 1 2 + 56 7 73 0 37 1 2 1 2 + 57 -28 73 0 100 1 2 1 2 + 58 -76 55 0 62 1 2 1 2 + 59 41 42 0 90 1 2 1 2 + 60 92 40 0 57 1 2 1 2 + 61 -84 -29 0 44 1 2 1 2 + 62 -12 42 0 37 1 2 1 2 + 63 51 -45 0 80 1 2 1 2 + 64 -37 46 0 60 1 2 1 2 + 65 -97 35 0 95 1 2 1 2 + 66 14 89 0 56 1 2 1 2 + 67 60 58 0 56 1 2 1 2 + 68 -63 -75 0 9 1 2 1 2 + 69 -18 34 0 39 1 2 1 2 + 70 -46 -82 0 15 1 2 1 2 + 71 -86 -79 0 4 1 2 1 2 + 72 -43 -30 0 58 1 2 1 2 + 73 -44 7 0 73 1 2 1 2 + 74 -3 -20 0 5 1 2 1 2 + 75 36 41 0 12 1 2 1 2 + 76 -30 -94 0 3 1 2 1 2 + 77 79 -62 0 8 1 2 1 2 + 78 51 70 0 31 1 2 1 2 + 79 -61 -26 0 48 1 2 1 2 + 80 6 94 0 3 1 2 1 2 + 81 -19 -62 0 52 1 2 1 2 + 82 -20 51 0 99 1 2 1 2 + 83 -81 37 0 29 1 2 1 2 + 84 7 31 0 12 1 2 1 2 + 85 52 12 0 50 1 2 1 2 + 86 83 -91 0 98 1 2 1 2 + 87 -7 -92 0 4 1 2 1 2 + 88 82 -74 0 56 1 2 1 2 + 89 -70 85 0 24 1 2 1 2 + 90 -83 -30 0 33 1 2 1 2 + 91 71 -61 0 45 1 2 1 2 + 92 85 11 0 98 1 2 1 2 + 93 66 -48 0 4 1 2 1 2 + 94 78 -87 0 36 1 2 1 2 + 95 9 -79 0 72 1 2 1 2 + 96 -36 4 0 26 1 2 1 2 + 97 66 39 0 71 1 2 1 2 + 98 92 -17 0 84 1 2 1 2 + 99 -46 -79 0 21 1 2 1 2 +100 -30 -63 0 99 1 2 1 2 +101 -42 63 0 33 1 2 1 2 +102 20 42 0 84 1 2 1 2 +103 15 98 0 74 1 2 1 2 +104 1 -17 0 93 1 2 1 2 +105 64 20 0 25 1 2 1 2 +106 -96 85 0 39 1 2 1 2 +107 93 -29 0 42 1 2 1 2 +108 -40 -84 0 77 1 2 1 2 +109 86 35 0 68 1 2 1 2 +110 91 36 0 50 1 2 1 2 +111 62 -8 0 42 1 2 1 2 +112 -24 4 0 71 1 2 1 2 +113 11 96 0 85 1 2 1 2 +114 -53 62 0 78 1 2 1 2 +115 -28 -71 0 64 1 2 1 2 +116 7 -4 0 5 1 2 1 2 +117 95 -9 0 93 1 2 1 2 +118 -3 17 0 18 1 2 1 2 +119 53 -90 0 38 1 2 1 2 +120 58 -19 0 29 1 2 1 2 +121 -83 84 0 81 1 2 1 2 +122 -1 49 0 4 1 2 1 2 +123 -4 17 0 23 1 2 1 2 +124 -82 -3 0 11 1 2 1 2 +125 -43 47 0 86 1 2 1 2 +126 6 -6 0 2 1 2 1 2 +127 70 99 0 31 1 2 1 2 +128 68 -29 0 54 1 2 1 2 +129 -94 -30 0 87 1 2 1 2 +130 -94 -20 0 17 1 2 1 2 +131 -21 77 0 81 1 2 1 2 +132 64 37 0 72 1 2 1 2 +133 -70 -19 0 10 1 2 1 2 +134 88 65 0 50 1 2 1 2 +135 2 29 0 25 1 2 1 2 +136 33 57 0 71 1 2 1 2 +137 -70 6 0 85 1 2 1 2 +138 -38 -56 0 51 1 2 1 2 +139 -80 -95 0 29 1 2 1 2 +140 -5 -39 0 55 1 2 1 2 +141 8 -22 0 45 1 2 1 2 +142 -61 -76 0 100 1 2 1 2 +143 76 -22 0 38 1 2 1 2 +144 49 -71 0 11 1 2 1 2 +145 -30 -68 0 82 1 2 1 2 +146 1 34 0 50 1 2 1 2 +147 77 79 0 39 1 2 1 2 +148 -58 64 0 6 1 2 1 2 +149 82 -97 0 87 1 2 1 2 +150 -80 55 0 83 1 2 1 2 +151 81 -86 0 22 1 2 1 2 +152 39 -49 0 24 1 2 1 2 +153 -67 72 0 69 1 2 1 2 +154 -25 -89 0 97 1 2 1 2 +155 -44 -95 0 65 1 2 1 2 +156 32 -68 0 97 1 2 1 2 +157 -17 49 0 79 1 2 1 2 +158 93 49 0 79 1 2 1 2 +159 99 81 0 46 1 2 1 2 +160 10 -49 0 52 1 2 1 2 +161 63 -41 0 39 1 2 1 2 +162 38 39 0 94 1 2 1 2 +163 -28 39 0 97 1 2 1 2 +164 -2 -47 0 18 1 2 1 2 +165 38 8 0 3 1 2 1 2 +166 -42 -6 0 23 1 2 1 2 +167 -67 88 0 19 1 2 1 2 +168 19 93 0 40 1 2 1 2 +169 40 27 0 49 1 2 1 2 +170 -61 56 0 96 1 2 1 2 +171 43 33 0 58 1 2 1 2 +172 -18 -39 0 15 1 2 1 2 +173 -69 19 0 21 1 2 1 2 +174 75 -18 0 56 1 2 1 2 +175 31 85 0 67 1 2 1 2 +176 25 58 0 10 1 2 1 2 +177 -16 36 0 36 1 2 1 2 +178 91 15 0 84 1 2 1 2 +179 60 -39 0 59 1 2 1 2 +180 49 -47 0 85 1 2 1 2 +181 42 33 0 60 1 2 1 2 +182 16 -81 0 33 1 2 1 2 +183 -78 53 0 62 1 2 1 2 +184 53 -80 0 70 1 2 1 2 +185 -46 -26 0 79 1 2 1 2 +186 -25 -54 0 98 1 2 1 2 +187 69 -46 0 99 1 2 1 2 +188 0 -78 0 18 1 2 1 2 +189 -84 74 0 55 1 2 1 2 +190 -16 16 0 75 1 2 1 2 +191 -63 -14 0 94 1 2 1 2 +192 51 -77 0 89 1 2 1 2 +193 -39 61 0 13 1 2 1 2 +194 5 97 0 19 1 2 1 2 +195 -55 39 0 19 1 2 1 2 +196 70 -14 0 90 1 2 1 2 +197 0 95 0 35 1 2 1 2 +198 -45 7 0 76 1 2 1 2 +199 38 -24 0 3 1 2 1 2 +200 50 -37 0 11 1 2 1 2 +201 59 71 0 98 1 2 1 2 +202 -73 -96 0 92 1 2 1 2 +203 -29 72 0 1 1 2 1 2 +204 -47 12 0 2 1 2 1 2 +205 -88 -61 0 63 1 2 1 2 +206 -88 36 0 57 1 2 1 2 +207 -46 -3 0 50 1 2 1 2 +208 26 -37 0 19 1 2 1 2 +209 -39 -67 0 24 1 2 1 2 +210 92 27 0 14 1 2 1 2 +211 -80 -31 0 18 1 2 1 2 +212 93 -50 0 77 1 2 1 2 +213 -20 -5 0 28 1 2 1 2 +214 -22 73 0 72 1 2 1 2 +215 -4 -7 0 49 1 2 1 2 +216 54 -48 0 58 1 2 1 2 +217 -70 39 0 84 1 2 1 2 +218 54 -82 0 58 1 2 1 2 +219 29 41 0 41 1 2 1 2 +220 -87 51 0 98 1 2 1 2 +221 -96 -36 0 77 1 2 1 2 +222 49 8 0 57 1 2 1 2 +223 -5 54 0 39 1 2 1 2 +224 -26 43 0 99 1 2 1 2 +225 -11 60 0 83 1 2 1 2 +226 40 61 0 54 1 2 1 2 +227 82 35 0 86 1 2 1 2 +228 -92 12 0 2 1 2 1 2 +229 -93 -86 0 14 1 2 1 2 +230 -66 63 0 42 1 2 1 2 +231 -72 -87 0 14 1 2 1 2 +232 -57 -84 0 55 1 2 1 2 +233 23 52 0 2 1 2 1 2 +234 -56 -62 0 18 1 2 1 2 +235 -19 59 0 17 1 2 1 2 +236 63 -14 0 22 1 2 1 2 +237 -13 38 0 28 1 2 1 2 +238 -19 87 0 3 1 2 1 2 +239 44 -84 0 96 1 2 1 2 +240 98 -17 0 53 1 2 1 2 +241 -16 62 0 15 1 2 1 2 +242 3 66 0 36 1 2 1 2 +243 26 22 0 98 1 2 1 2 +244 -38 -81 0 78 1 2 1 2 +245 70 -80 0 92 1 2 1 2 +246 17 -35 0 65 1 2 1 2 +247 96 -83 0 64 1 2 1 2 +248 -77 80 0 43 1 2 1 2 +249 -14 44 0 50 1 2 1 2 +250 -33 33 0 0 0 0 +251 33 -33 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p08.res b/jsprit-instances/instances/cordeau/p08.res new file mode 100644 index 00000000..03301944 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p08.res @@ -0,0 +1,26 @@ +4437.68 +1 1 273.48 494 0 237 122 233 176 136 78 24 127 40 17 175 55 47 56 0 +1 2 133.14 473 0 73 198 207 19 185 72 166 96 0 +1 3 138.48 496 0 69 146 135 84 15 102 39 38 223 43 0 +1 4 115.54 496 0 125 101 203 57 131 214 11 241 225 0 +1 5 188.96 487 0 235 238 10 42 197 194 80 113 103 168 66 242 0 +1 6 191.58 488 0 148 26 9 153 189 106 121 248 89 167 13 193 0 +1 7 59.02 497 0 177 62 249 157 82 224 163 0 +1 8 122.55 495 0 114 230 58 150 183 170 2 0 +1 9 162.05 475 0 27 173 137 124 49 12 133 5 191 30 18 54 0 +1 10 281.96 482 0 195 228 53 130 129 221 31 205 61 90 211 79 204 0 +1 11 147.83 497 0 217 83 206 65 220 36 64 0 +1 12 148.28 493 0 190 8 123 118 3 116 126 104 215 213 112 0 +2 1 209.02 498 0 199 222 85 132 97 51 67 169 6 37 0 +2 2 175.08 498 0 165 181 171 59 162 219 52 243 16 0 +2 3 97.66 482 0 180 63 46 93 187 45 161 179 200 0 +2 4 165.62 486 0 7 140 186 21 138 100 145 81 0 +2 5 309.78 491 0 164 209 142 68 231 71 229 1 139 202 232 70 115 4 208 0 +2 6 266.60 493 0 188 87 154 76 155 108 244 99 234 33 172 74 141 0 +2 7 138.41 425 0 28 182 34 95 160 246 25 0 +2 8 185.69 459 0 50 88 247 149 86 151 94 245 0 +2 9 109.58 412 0 22 120 236 111 196 174 48 128 0 +2 10 187.86 499 0 143 14 98 117 240 107 212 77 91 216 0 +2 11 139.09 492 0 152 144 192 184 218 119 239 35 156 0 +2 12 193.07 500 0 23 92 178 210 41 109 20 227 29 105 44 0 +2 13 297.34 498 0 110 60 158 134 159 147 201 32 226 75 0 diff --git a/jsprit-instances/instances/cordeau/p09 b/jsprit-instances/instances/cordeau/p09 new file mode 100644 index 00000000..e2fa2ab7 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p09 @@ -0,0 +1,256 @@ +2 12 249 3 +310 500 +310 500 +310 500 + 1 -99 -97 0 6 1 3 1 2 4 + 2 -59 50 0 72 1 3 1 2 4 + 3 0 14 0 93 1 3 1 2 4 + 4 -17 -66 0 28 1 3 1 2 4 + 5 -69 -19 0 5 1 3 1 2 4 + 6 31 12 0 43 1 3 1 2 4 + 7 5 -41 0 1 1 3 1 2 4 + 8 -12 10 0 36 1 3 1 2 4 + 9 -64 70 0 53 1 3 1 2 4 + 10 -12 85 0 63 1 3 1 2 4 + 11 -18 64 0 25 1 3 1 2 4 + 12 -77 -16 0 50 1 3 1 2 4 + 13 -53 88 0 57 1 3 1 2 4 + 14 83 -24 0 1 1 3 1 2 4 + 15 24 41 0 66 1 3 1 2 4 + 16 17 21 0 37 1 3 1 2 4 + 17 42 96 0 51 1 3 1 2 4 + 18 -65 0 0 47 1 3 1 2 4 + 19 -47 -26 0 88 1 3 1 2 4 + 20 85 36 0 75 1 3 1 2 4 + 21 -35 -54 0 48 1 3 1 2 4 + 22 54 -21 0 40 1 3 1 2 4 + 23 64 -17 0 8 1 3 1 2 4 + 24 55 89 0 69 1 3 1 2 4 + 25 17 -25 0 93 1 3 1 2 4 + 26 -61 66 0 29 1 3 1 2 4 + 27 -61 26 0 5 1 3 1 2 4 + 28 17 -72 0 53 1 3 1 2 4 + 29 79 38 0 8 1 3 1 2 4 + 30 -62 -2 0 24 1 3 1 2 4 + 31 -90 -68 0 53 1 3 1 2 4 + 32 52 66 0 13 1 3 1 2 4 + 33 -54 -50 0 47 1 3 1 2 4 + 34 8 -84 0 57 1 3 1 2 4 + 35 37 -90 0 9 1 3 1 2 4 + 36 -83 49 0 74 1 3 1 2 4 + 37 35 -1 0 83 1 3 1 2 4 + 38 7 59 0 96 1 3 1 2 4 + 39 12 48 0 42 1 3 1 2 4 + 40 57 95 0 80 1 3 1 2 4 + 41 92 28 0 22 1 3 1 2 4 + 42 -3 97 0 56 1 3 1 2 4 + 43 -7 52 0 43 1 3 1 2 4 + 44 42 -15 0 12 1 3 1 2 4 + 45 77 -43 0 73 1 3 1 2 4 + 46 59 -49 0 32 1 3 1 2 4 + 47 25 91 0 8 1 3 1 2 4 + 48 69 -19 0 79 1 3 1 2 4 + 49 -82 -14 0 79 1 3 1 2 4 + 50 74 -70 0 4 1 3 1 2 4 + 51 69 59 0 14 1 3 1 2 4 + 52 29 33 0 17 1 3 1 2 4 + 53 -97 9 0 19 1 3 1 2 4 + 54 -58 9 0 44 1 3 1 2 4 + 55 28 93 0 5 1 3 1 2 4 + 56 7 73 0 37 1 3 1 2 4 + 57 -28 73 0 100 1 3 1 2 4 + 58 -76 55 0 62 1 3 1 2 4 + 59 41 42 0 90 1 3 1 2 4 + 60 92 40 0 57 1 3 1 2 4 + 61 -84 -29 0 44 1 3 1 2 4 + 62 -12 42 0 37 1 3 1 2 4 + 63 51 -45 0 80 1 3 1 2 4 + 64 -37 46 0 60 1 3 1 2 4 + 65 -97 35 0 95 1 3 1 2 4 + 66 14 89 0 56 1 3 1 2 4 + 67 60 58 0 56 1 3 1 2 4 + 68 -63 -75 0 9 1 3 1 2 4 + 69 -18 34 0 39 1 3 1 2 4 + 70 -46 -82 0 15 1 3 1 2 4 + 71 -86 -79 0 4 1 3 1 2 4 + 72 -43 -30 0 58 1 3 1 2 4 + 73 -44 7 0 73 1 3 1 2 4 + 74 -3 -20 0 5 1 3 1 2 4 + 75 36 41 0 12 1 3 1 2 4 + 76 -30 -94 0 3 1 3 1 2 4 + 77 79 -62 0 8 1 3 1 2 4 + 78 51 70 0 31 1 3 1 2 4 + 79 -61 -26 0 48 1 3 1 2 4 + 80 6 94 0 3 1 3 1 2 4 + 81 -19 -62 0 52 1 3 1 2 4 + 82 -20 51 0 99 1 3 1 2 4 + 83 -81 37 0 29 1 3 1 2 4 + 84 7 31 0 12 1 3 1 2 4 + 85 52 12 0 50 1 3 1 2 4 + 86 83 -91 0 98 1 3 1 2 4 + 87 -7 -92 0 4 1 3 1 2 4 + 88 82 -74 0 56 1 3 1 2 4 + 89 -70 85 0 24 1 3 1 2 4 + 90 -83 -30 0 33 1 3 1 2 4 + 91 71 -61 0 45 1 3 1 2 4 + 92 85 11 0 98 1 3 1 2 4 + 93 66 -48 0 4 1 3 1 2 4 + 94 78 -87 0 36 1 3 1 2 4 + 95 9 -79 0 72 1 3 1 2 4 + 96 -36 4 0 26 1 3 1 2 4 + 97 66 39 0 71 1 3 1 2 4 + 98 92 -17 0 84 1 3 1 2 4 + 99 -46 -79 0 21 1 3 1 2 4 +100 -30 -63 0 99 1 3 1 2 4 +101 -42 63 0 33 1 3 1 2 4 +102 20 42 0 84 1 3 1 2 4 +103 15 98 0 74 1 3 1 2 4 +104 1 -17 0 93 1 3 1 2 4 +105 64 20 0 25 1 3 1 2 4 +106 -96 85 0 39 1 3 1 2 4 +107 93 -29 0 42 1 3 1 2 4 +108 -40 -84 0 77 1 3 1 2 4 +109 86 35 0 68 1 3 1 2 4 +110 91 36 0 50 1 3 1 2 4 +111 62 -8 0 42 1 3 1 2 4 +112 -24 4 0 71 1 3 1 2 4 +113 11 96 0 85 1 3 1 2 4 +114 -53 62 0 78 1 3 1 2 4 +115 -28 -71 0 64 1 3 1 2 4 +116 7 -4 0 5 1 3 1 2 4 +117 95 -9 0 93 1 3 1 2 4 +118 -3 17 0 18 1 3 1 2 4 +119 53 -90 0 38 1 3 1 2 4 +120 58 -19 0 29 1 3 1 2 4 +121 -83 84 0 81 1 3 1 2 4 +122 -1 49 0 4 1 3 1 2 4 +123 -4 17 0 23 1 3 1 2 4 +124 -82 -3 0 11 1 3 1 2 4 +125 -43 47 0 86 1 3 1 2 4 +126 6 -6 0 2 1 3 1 2 4 +127 70 99 0 31 1 3 1 2 4 +128 68 -29 0 54 1 3 1 2 4 +129 -94 -30 0 87 1 3 1 2 4 +130 -94 -20 0 17 1 3 1 2 4 +131 -21 77 0 81 1 3 1 2 4 +132 64 37 0 72 1 3 1 2 4 +133 -70 -19 0 10 1 3 1 2 4 +134 88 65 0 50 1 3 1 2 4 +135 2 29 0 25 1 3 1 2 4 +136 33 57 0 71 1 3 1 2 4 +137 -70 6 0 85 1 3 1 2 4 +138 -38 -56 0 51 1 3 1 2 4 +139 -80 -95 0 29 1 3 1 2 4 +140 -5 -39 0 55 1 3 1 2 4 +141 8 -22 0 45 1 3 1 2 4 +142 -61 -76 0 100 1 3 1 2 4 +143 76 -22 0 38 1 3 1 2 4 +144 49 -71 0 11 1 3 1 2 4 +145 -30 -68 0 82 1 3 1 2 4 +146 1 34 0 50 1 3 1 2 4 +147 77 79 0 39 1 3 1 2 4 +148 -58 64 0 6 1 3 1 2 4 +149 82 -97 0 87 1 3 1 2 4 +150 -80 55 0 83 1 3 1 2 4 +151 81 -86 0 22 1 3 1 2 4 +152 39 -49 0 24 1 3 1 2 4 +153 -67 72 0 69 1 3 1 2 4 +154 -25 -89 0 97 1 3 1 2 4 +155 -44 -95 0 65 1 3 1 2 4 +156 32 -68 0 97 1 3 1 2 4 +157 -17 49 0 79 1 3 1 2 4 +158 93 49 0 79 1 3 1 2 4 +159 99 81 0 46 1 3 1 2 4 +160 10 -49 0 52 1 3 1 2 4 +161 63 -41 0 39 1 3 1 2 4 +162 38 39 0 94 1 3 1 2 4 +163 -28 39 0 97 1 3 1 2 4 +164 -2 -47 0 18 1 3 1 2 4 +165 38 8 0 3 1 3 1 2 4 +166 -42 -6 0 23 1 3 1 2 4 +167 -67 88 0 19 1 3 1 2 4 +168 19 93 0 40 1 3 1 2 4 +169 40 27 0 49 1 3 1 2 4 +170 -61 56 0 96 1 3 1 2 4 +171 43 33 0 58 1 3 1 2 4 +172 -18 -39 0 15 1 3 1 2 4 +173 -69 19 0 21 1 3 1 2 4 +174 75 -18 0 56 1 3 1 2 4 +175 31 85 0 67 1 3 1 2 4 +176 25 58 0 10 1 3 1 2 4 +177 -16 36 0 36 1 3 1 2 4 +178 91 15 0 84 1 3 1 2 4 +179 60 -39 0 59 1 3 1 2 4 +180 49 -47 0 85 1 3 1 2 4 +181 42 33 0 60 1 3 1 2 4 +182 16 -81 0 33 1 3 1 2 4 +183 -78 53 0 62 1 3 1 2 4 +184 53 -80 0 70 1 3 1 2 4 +185 -46 -26 0 79 1 3 1 2 4 +186 -25 -54 0 98 1 3 1 2 4 +187 69 -46 0 99 1 3 1 2 4 +188 0 -78 0 18 1 3 1 2 4 +189 -84 74 0 55 1 3 1 2 4 +190 -16 16 0 75 1 3 1 2 4 +191 -63 -14 0 94 1 3 1 2 4 +192 51 -77 0 89 1 3 1 2 4 +193 -39 61 0 13 1 3 1 2 4 +194 5 97 0 19 1 3 1 2 4 +195 -55 39 0 19 1 3 1 2 4 +196 70 -14 0 90 1 3 1 2 4 +197 0 95 0 35 1 3 1 2 4 +198 -45 7 0 76 1 3 1 2 4 +199 38 -24 0 3 1 3 1 2 4 +200 50 -37 0 11 1 3 1 2 4 +201 59 71 0 98 1 3 1 2 4 +202 -73 -96 0 92 1 3 1 2 4 +203 -29 72 0 1 1 3 1 2 4 +204 -47 12 0 2 1 3 1 2 4 +205 -88 -61 0 63 1 3 1 2 4 +206 -88 36 0 57 1 3 1 2 4 +207 -46 -3 0 50 1 3 1 2 4 +208 26 -37 0 19 1 3 1 2 4 +209 -39 -67 0 24 1 3 1 2 4 +210 92 27 0 14 1 3 1 2 4 +211 -80 -31 0 18 1 3 1 2 4 +212 93 -50 0 77 1 3 1 2 4 +213 -20 -5 0 28 1 3 1 2 4 +214 -22 73 0 72 1 3 1 2 4 +215 -4 -7 0 49 1 3 1 2 4 +216 54 -48 0 58 1 3 1 2 4 +217 -70 39 0 84 1 3 1 2 4 +218 54 -82 0 58 1 3 1 2 4 +219 29 41 0 41 1 3 1 2 4 +220 -87 51 0 98 1 3 1 2 4 +221 -96 -36 0 77 1 3 1 2 4 +222 49 8 0 57 1 3 1 2 4 +223 -5 54 0 39 1 3 1 2 4 +224 -26 43 0 99 1 3 1 2 4 +225 -11 60 0 83 1 3 1 2 4 +226 40 61 0 54 1 3 1 2 4 +227 82 35 0 86 1 3 1 2 4 +228 -92 12 0 2 1 3 1 2 4 +229 -93 -86 0 14 1 3 1 2 4 +230 -66 63 0 42 1 3 1 2 4 +231 -72 -87 0 14 1 3 1 2 4 +232 -57 -84 0 55 1 3 1 2 4 +233 23 52 0 2 1 3 1 2 4 +234 -56 -62 0 18 1 3 1 2 4 +235 -19 59 0 17 1 3 1 2 4 +236 63 -14 0 22 1 3 1 2 4 +237 -13 38 0 28 1 3 1 2 4 +238 -19 87 0 3 1 3 1 2 4 +239 44 -84 0 96 1 3 1 2 4 +240 98 -17 0 53 1 3 1 2 4 +241 -16 62 0 15 1 3 1 2 4 +242 3 66 0 36 1 3 1 2 4 +243 26 22 0 98 1 3 1 2 4 +244 -38 -81 0 78 1 3 1 2 4 +245 70 -80 0 92 1 3 1 2 4 +246 17 -35 0 65 1 3 1 2 4 +247 96 -83 0 64 1 3 1 2 4 +248 -77 80 0 43 1 3 1 2 4 +249 -14 44 0 50 1 3 1 2 4 +250 70 0 0 0 0 0 +251 -50 60 0 0 0 0 +252 -50 -60 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p09.res b/jsprit-instances/instances/cordeau/p09.res new file mode 100644 index 00000000..bc87a358 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p09.res @@ -0,0 +1,27 @@ +3900.22 +1 1 274.07 495 0 226 175 17 24 40 127 147 159 134 29 0 +1 2 93.59 497 0 227 20 109 110 41 210 178 92 0 +1 3 153.00 495 0 169 52 219 15 102 16 243 6 165 222 0 +1 4 190.11 474 0 44 199 208 246 25 141 104 74 215 126 116 37 0 +1 5 118.45 497 0 236 179 161 46 216 180 63 200 22 120 111 0 +1 6 215.13 500 0 23 144 192 184 218 119 239 35 156 152 0 +1 7 82.40 414 0 196 174 143 98 240 117 0 +1 8 219.07 471 0 93 50 245 94 151 86 149 247 88 77 0 +1 9 153.47 470 0 14 107 212 91 187 45 128 48 0 +1 10 180.06 491 0 60 158 51 201 78 32 67 97 132 0 +1 11 156.64 472 0 105 59 136 176 233 75 162 181 171 85 0 +2 1 113.37 497 0 58 220 65 206 83 217 2 0 +2 2 173.35 490 0 204 73 198 54 30 191 18 137 173 27 195 0 +2 3 164.62 498 0 157 249 62 146 84 135 3 118 123 8 190 0 +2 4 129.81 475 0 148 26 9 153 189 106 121 248 89 167 13 0 +2 5 68.69 287 0 203 57 131 214 101 0 +2 6 192.61 499 0 241 56 66 47 55 168 103 113 80 194 197 42 10 238 0 +2 7 74.85 435 0 114 230 150 36 183 170 0 +2 8 93.20 445 0 224 237 177 69 163 64 125 0 +2 9 146.31 497 0 193 235 11 225 242 38 39 122 223 43 82 0 +3 1 200.90 500 0 79 5 133 12 49 124 228 53 130 129 221 61 90 211 0 +3 2 161.31 457 0 68 142 232 231 202 139 1 229 71 31 205 234 0 +3 3 77.55 365 0 209 115 4 81 186 21 138 0 +3 4 91.37 437 0 100 145 244 108 155 70 99 0 +3 5 214.37 478 0 172 140 164 7 160 28 182 95 34 188 87 154 76 0 +3 6 161.92 470 0 213 112 96 207 166 19 185 72 33 0 diff --git a/jsprit-instances/instances/cordeau/p10 b/jsprit-instances/instances/cordeau/p10 new file mode 100644 index 00000000..88237489 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p10 @@ -0,0 +1,258 @@ +2 8 249 4 +310 500 +310 500 +310 500 +310 500 + 1 -99 -97 0 6 1 4 1 2 4 8 + 2 -59 50 0 72 1 4 1 2 4 8 + 3 0 14 0 93 1 4 1 2 4 8 + 4 -17 -66 0 28 1 4 1 2 4 8 + 5 -69 -19 0 5 1 4 1 2 4 8 + 6 31 12 0 43 1 4 1 2 4 8 + 7 5 -41 0 1 1 4 1 2 4 8 + 8 -12 10 0 36 1 4 1 2 4 8 + 9 -64 70 0 53 1 4 1 2 4 8 + 10 -12 85 0 63 1 4 1 2 4 8 + 11 -18 64 0 25 1 4 1 2 4 8 + 12 -77 -16 0 50 1 4 1 2 4 8 + 13 -53 88 0 57 1 4 1 2 4 8 + 14 83 -24 0 1 1 4 1 2 4 8 + 15 24 41 0 66 1 4 1 2 4 8 + 16 17 21 0 37 1 4 1 2 4 8 + 17 42 96 0 51 1 4 1 2 4 8 + 18 -65 0 0 47 1 4 1 2 4 8 + 19 -47 -26 0 88 1 4 1 2 4 8 + 20 85 36 0 75 1 4 1 2 4 8 + 21 -35 -54 0 48 1 4 1 2 4 8 + 22 54 -21 0 40 1 4 1 2 4 8 + 23 64 -17 0 8 1 4 1 2 4 8 + 24 55 89 0 69 1 4 1 2 4 8 + 25 17 -25 0 93 1 4 1 2 4 8 + 26 -61 66 0 29 1 4 1 2 4 8 + 27 -61 26 0 5 1 4 1 2 4 8 + 28 17 -72 0 53 1 4 1 2 4 8 + 29 79 38 0 8 1 4 1 2 4 8 + 30 -62 -2 0 24 1 4 1 2 4 8 + 31 -90 -68 0 53 1 4 1 2 4 8 + 32 52 66 0 13 1 4 1 2 4 8 + 33 -54 -50 0 47 1 4 1 2 4 8 + 34 8 -84 0 57 1 4 1 2 4 8 + 35 37 -90 0 9 1 4 1 2 4 8 + 36 -83 49 0 74 1 4 1 2 4 8 + 37 35 -1 0 83 1 4 1 2 4 8 + 38 7 59 0 96 1 4 1 2 4 8 + 39 12 48 0 42 1 4 1 2 4 8 + 40 57 95 0 80 1 4 1 2 4 8 + 41 92 28 0 22 1 4 1 2 4 8 + 42 -3 97 0 56 1 4 1 2 4 8 + 43 -7 52 0 43 1 4 1 2 4 8 + 44 42 -15 0 12 1 4 1 2 4 8 + 45 77 -43 0 73 1 4 1 2 4 8 + 46 59 -49 0 32 1 4 1 2 4 8 + 47 25 91 0 8 1 4 1 2 4 8 + 48 69 -19 0 79 1 4 1 2 4 8 + 49 -82 -14 0 79 1 4 1 2 4 8 + 50 74 -70 0 4 1 4 1 2 4 8 + 51 69 59 0 14 1 4 1 2 4 8 + 52 29 33 0 17 1 4 1 2 4 8 + 53 -97 9 0 19 1 4 1 2 4 8 + 54 -58 9 0 44 1 4 1 2 4 8 + 55 28 93 0 5 1 4 1 2 4 8 + 56 7 73 0 37 1 4 1 2 4 8 + 57 -28 73 0 100 1 4 1 2 4 8 + 58 -76 55 0 62 1 4 1 2 4 8 + 59 41 42 0 90 1 4 1 2 4 8 + 60 92 40 0 57 1 4 1 2 4 8 + 61 -84 -29 0 44 1 4 1 2 4 8 + 62 -12 42 0 37 1 4 1 2 4 8 + 63 51 -45 0 80 1 4 1 2 4 8 + 64 -37 46 0 60 1 4 1 2 4 8 + 65 -97 35 0 95 1 4 1 2 4 8 + 66 14 89 0 56 1 4 1 2 4 8 + 67 60 58 0 56 1 4 1 2 4 8 + 68 -63 -75 0 9 1 4 1 2 4 8 + 69 -18 34 0 39 1 4 1 2 4 8 + 70 -46 -82 0 15 1 4 1 2 4 8 + 71 -86 -79 0 4 1 4 1 2 4 8 + 72 -43 -30 0 58 1 4 1 2 4 8 + 73 -44 7 0 73 1 4 1 2 4 8 + 74 -3 -20 0 5 1 4 1 2 4 8 + 75 36 41 0 12 1 4 1 2 4 8 + 76 -30 -94 0 3 1 4 1 2 4 8 + 77 79 -62 0 8 1 4 1 2 4 8 + 78 51 70 0 31 1 4 1 2 4 8 + 79 -61 -26 0 48 1 4 1 2 4 8 + 80 6 94 0 3 1 4 1 2 4 8 + 81 -19 -62 0 52 1 4 1 2 4 8 + 82 -20 51 0 99 1 4 1 2 4 8 + 83 -81 37 0 29 1 4 1 2 4 8 + 84 7 31 0 12 1 4 1 2 4 8 + 85 52 12 0 50 1 4 1 2 4 8 + 86 83 -91 0 98 1 4 1 2 4 8 + 87 -7 -92 0 4 1 4 1 2 4 8 + 88 82 -74 0 56 1 4 1 2 4 8 + 89 -70 85 0 24 1 4 1 2 4 8 + 90 -83 -30 0 33 1 4 1 2 4 8 + 91 71 -61 0 45 1 4 1 2 4 8 + 92 85 11 0 98 1 4 1 2 4 8 + 93 66 -48 0 4 1 4 1 2 4 8 + 94 78 -87 0 36 1 4 1 2 4 8 + 95 9 -79 0 72 1 4 1 2 4 8 + 96 -36 4 0 26 1 4 1 2 4 8 + 97 66 39 0 71 1 4 1 2 4 8 + 98 92 -17 0 84 1 4 1 2 4 8 + 99 -46 -79 0 21 1 4 1 2 4 8 +100 -30 -63 0 99 1 4 1 2 4 8 +101 -42 63 0 33 1 4 1 2 4 8 +102 20 42 0 84 1 4 1 2 4 8 +103 15 98 0 74 1 4 1 2 4 8 +104 1 -17 0 93 1 4 1 2 4 8 +105 64 20 0 25 1 4 1 2 4 8 +106 -96 85 0 39 1 4 1 2 4 8 +107 93 -29 0 42 1 4 1 2 4 8 +108 -40 -84 0 77 1 4 1 2 4 8 +109 86 35 0 68 1 4 1 2 4 8 +110 91 36 0 50 1 4 1 2 4 8 +111 62 -8 0 42 1 4 1 2 4 8 +112 -24 4 0 71 1 4 1 2 4 8 +113 11 96 0 85 1 4 1 2 4 8 +114 -53 62 0 78 1 4 1 2 4 8 +115 -28 -71 0 64 1 4 1 2 4 8 +116 7 -4 0 5 1 4 1 2 4 8 +117 95 -9 0 93 1 4 1 2 4 8 +118 -3 17 0 18 1 4 1 2 4 8 +119 53 -90 0 38 1 4 1 2 4 8 +120 58 -19 0 29 1 4 1 2 4 8 +121 -83 84 0 81 1 4 1 2 4 8 +122 -1 49 0 4 1 4 1 2 4 8 +123 -4 17 0 23 1 4 1 2 4 8 +124 -82 -3 0 11 1 4 1 2 4 8 +125 -43 47 0 86 1 4 1 2 4 8 +126 6 -6 0 2 1 4 1 2 4 8 +127 70 99 0 31 1 4 1 2 4 8 +128 68 -29 0 54 1 4 1 2 4 8 +129 -94 -30 0 87 1 4 1 2 4 8 +130 -94 -20 0 17 1 4 1 2 4 8 +131 -21 77 0 81 1 4 1 2 4 8 +132 64 37 0 72 1 4 1 2 4 8 +133 -70 -19 0 10 1 4 1 2 4 8 +134 88 65 0 50 1 4 1 2 4 8 +135 2 29 0 25 1 4 1 2 4 8 +136 33 57 0 71 1 4 1 2 4 8 +137 -70 6 0 85 1 4 1 2 4 8 +138 -38 -56 0 51 1 4 1 2 4 8 +139 -80 -95 0 29 1 4 1 2 4 8 +140 -5 -39 0 55 1 4 1 2 4 8 +141 8 -22 0 45 1 4 1 2 4 8 +142 -61 -76 0 100 1 4 1 2 4 8 +143 76 -22 0 38 1 4 1 2 4 8 +144 49 -71 0 11 1 4 1 2 4 8 +145 -30 -68 0 82 1 4 1 2 4 8 +146 1 34 0 50 1 4 1 2 4 8 +147 77 79 0 39 1 4 1 2 4 8 +148 -58 64 0 6 1 4 1 2 4 8 +149 82 -97 0 87 1 4 1 2 4 8 +150 -80 55 0 83 1 4 1 2 4 8 +151 81 -86 0 22 1 4 1 2 4 8 +152 39 -49 0 24 1 4 1 2 4 8 +153 -67 72 0 69 1 4 1 2 4 8 +154 -25 -89 0 97 1 4 1 2 4 8 +155 -44 -95 0 65 1 4 1 2 4 8 +156 32 -68 0 97 1 4 1 2 4 8 +157 -17 49 0 79 1 4 1 2 4 8 +158 93 49 0 79 1 4 1 2 4 8 +159 99 81 0 46 1 4 1 2 4 8 +160 10 -49 0 52 1 4 1 2 4 8 +161 63 -41 0 39 1 4 1 2 4 8 +162 38 39 0 94 1 4 1 2 4 8 +163 -28 39 0 97 1 4 1 2 4 8 +164 -2 -47 0 18 1 4 1 2 4 8 +165 38 8 0 3 1 4 1 2 4 8 +166 -42 -6 0 23 1 4 1 2 4 8 +167 -67 88 0 19 1 4 1 2 4 8 +168 19 93 0 40 1 4 1 2 4 8 +169 40 27 0 49 1 4 1 2 4 8 +170 -61 56 0 96 1 4 1 2 4 8 +171 43 33 0 58 1 4 1 2 4 8 +172 -18 -39 0 15 1 4 1 2 4 8 +173 -69 19 0 21 1 4 1 2 4 8 +174 75 -18 0 56 1 4 1 2 4 8 +175 31 85 0 67 1 4 1 2 4 8 +176 25 58 0 10 1 4 1 2 4 8 +177 -16 36 0 36 1 4 1 2 4 8 +178 91 15 0 84 1 4 1 2 4 8 +179 60 -39 0 59 1 4 1 2 4 8 +180 49 -47 0 85 1 4 1 2 4 8 +181 42 33 0 60 1 4 1 2 4 8 +182 16 -81 0 33 1 4 1 2 4 8 +183 -78 53 0 62 1 4 1 2 4 8 +184 53 -80 0 70 1 4 1 2 4 8 +185 -46 -26 0 79 1 4 1 2 4 8 +186 -25 -54 0 98 1 4 1 2 4 8 +187 69 -46 0 99 1 4 1 2 4 8 +188 0 -78 0 18 1 4 1 2 4 8 +189 -84 74 0 55 1 4 1 2 4 8 +190 -16 16 0 75 1 4 1 2 4 8 +191 -63 -14 0 94 1 4 1 2 4 8 +192 51 -77 0 89 1 4 1 2 4 8 +193 -39 61 0 13 1 4 1 2 4 8 +194 5 97 0 19 1 4 1 2 4 8 +195 -55 39 0 19 1 4 1 2 4 8 +196 70 -14 0 90 1 4 1 2 4 8 +197 0 95 0 35 1 4 1 2 4 8 +198 -45 7 0 76 1 4 1 2 4 8 +199 38 -24 0 3 1 4 1 2 4 8 +200 50 -37 0 11 1 4 1 2 4 8 +201 59 71 0 98 1 4 1 2 4 8 +202 -73 -96 0 92 1 4 1 2 4 8 +203 -29 72 0 1 1 4 1 2 4 8 +204 -47 12 0 2 1 4 1 2 4 8 +205 -88 -61 0 63 1 4 1 2 4 8 +206 -88 36 0 57 1 4 1 2 4 8 +207 -46 -3 0 50 1 4 1 2 4 8 +208 26 -37 0 19 1 4 1 2 4 8 +209 -39 -67 0 24 1 4 1 2 4 8 +210 92 27 0 14 1 4 1 2 4 8 +211 -80 -31 0 18 1 4 1 2 4 8 +212 93 -50 0 77 1 4 1 2 4 8 +213 -20 -5 0 28 1 4 1 2 4 8 +214 -22 73 0 72 1 4 1 2 4 8 +215 -4 -7 0 49 1 4 1 2 4 8 +216 54 -48 0 58 1 4 1 2 4 8 +217 -70 39 0 84 1 4 1 2 4 8 +218 54 -82 0 58 1 4 1 2 4 8 +219 29 41 0 41 1 4 1 2 4 8 +220 -87 51 0 98 1 4 1 2 4 8 +221 -96 -36 0 77 1 4 1 2 4 8 +222 49 8 0 57 1 4 1 2 4 8 +223 -5 54 0 39 1 4 1 2 4 8 +224 -26 43 0 99 1 4 1 2 4 8 +225 -11 60 0 83 1 4 1 2 4 8 +226 40 61 0 54 1 4 1 2 4 8 +227 82 35 0 86 1 4 1 2 4 8 +228 -92 12 0 2 1 4 1 2 4 8 +229 -93 -86 0 14 1 4 1 2 4 8 +230 -66 63 0 42 1 4 1 2 4 8 +231 -72 -87 0 14 1 4 1 2 4 8 +232 -57 -84 0 55 1 4 1 2 4 8 +233 23 52 0 2 1 4 1 2 4 8 +234 -56 -62 0 18 1 4 1 2 4 8 +235 -19 59 0 17 1 4 1 2 4 8 +236 63 -14 0 22 1 4 1 2 4 8 +237 -13 38 0 28 1 4 1 2 4 8 +238 -19 87 0 3 1 4 1 2 4 8 +239 44 -84 0 96 1 4 1 2 4 8 +240 98 -17 0 53 1 4 1 2 4 8 +241 -16 62 0 15 1 4 1 2 4 8 +242 3 66 0 36 1 4 1 2 4 8 +243 26 22 0 98 1 4 1 2 4 8 +244 -38 -81 0 78 1 4 1 2 4 8 +245 70 -80 0 92 1 4 1 2 4 8 +246 17 -35 0 65 1 4 1 2 4 8 +247 96 -83 0 64 1 4 1 2 4 8 +248 -77 80 0 43 1 4 1 2 4 8 +249 -14 44 0 50 1 4 1 2 4 8 +250 75 0 0 0 0 0 +251 0 75 0 0 0 0 +252 -75 0 0 0 0 0 +253 0 -75 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p10.res b/jsprit-instances/instances/cordeau/p10.res new file mode 100644 index 00000000..ddc52041 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p10.res @@ -0,0 +1,27 @@ +3663.02 +1 1 131.84 480 0 111 236 23 120 22 200 179 161 93 187 45 128 0 +1 2 137.33 496 0 85 169 52 219 75 162 59 181 171 105 0 +1 3 192.98 488 0 37 116 126 215 3 118 16 243 6 165 222 0 +1 4 210.64 492 0 132 97 67 51 147 159 134 158 60 29 0 +1 5 88.55 497 0 92 178 210 41 110 109 20 227 0 +1 6 85.33 494 0 117 240 98 14 143 174 48 196 0 +1 7 202.45 485 0 107 212 77 91 46 216 63 180 152 208 199 44 0 +2 1 120.05 498 0 242 38 39 102 15 233 136 226 176 56 0 +2 2 208.98 497 0 114 26 153 189 106 121 248 89 167 13 238 0 +2 3 93.39 489 0 225 157 163 224 82 235 241 0 +2 4 81.49 391 0 10 42 197 194 80 113 103 66 0 +2 5 151.04 497 0 122 146 84 135 123 8 190 69 177 237 62 249 43 223 0 +2 6 185.49 493 0 175 78 32 201 127 40 24 17 55 47 168 0 +2 7 119.96 471 0 131 214 57 203 101 193 125 64 11 0 +3 1 124.88 484 0 173 217 58 183 150 220 36 0 +3 2 94.98 398 0 12 61 90 221 129 130 49 124 0 +3 3 238.45 482 0 133 5 33 234 142 68 231 202 139 1 229 71 31 205 211 0 +3 4 123.67 440 0 18 207 166 213 112 96 73 198 204 54 0 +3 5 102.47 476 0 191 79 72 185 19 30 137 0 +3 6 185.47 495 0 27 195 2 170 148 9 230 83 206 65 228 53 0 +4 1 157.62 442 0 160 7 246 25 141 104 74 172 140 164 0 +4 2 104.01 482 0 4 81 186 21 138 209 100 145 0 +4 3 143.06 497 0 188 87 154 76 155 232 70 99 108 244 115 0 +4 4 37.71 162 0 95 182 34 0 +4 5 219.62 497 0 50 88 247 149 86 151 94 245 119 0 +4 6 121.56 483 0 35 239 218 184 192 144 156 28 0 diff --git a/jsprit-instances/instances/cordeau/p11 b/jsprit-instances/instances/cordeau/p11 new file mode 100644 index 00000000..82bfcfed --- /dev/null +++ b/jsprit-instances/instances/cordeau/p11 @@ -0,0 +1,260 @@ +2 6 249 5 +310 500 +310 500 +310 500 +310 500 +310 500 + 1 -99 -97 0 6 1 5 1 2 4 8 16 + 2 -59 50 0 72 1 5 1 2 4 8 16 + 3 0 14 0 93 1 5 1 2 4 8 16 + 4 -17 -66 0 28 1 5 1 2 4 8 16 + 5 -69 -19 0 5 1 5 1 2 4 8 16 + 6 31 12 0 43 1 5 1 2 4 8 16 + 7 5 -41 0 1 1 5 1 2 4 8 16 + 8 -12 10 0 36 1 5 1 2 4 8 16 + 9 -64 70 0 53 1 5 1 2 4 8 16 + 10 -12 85 0 63 1 5 1 2 4 8 16 + 11 -18 64 0 25 1 5 1 2 4 8 16 + 12 -77 -16 0 50 1 5 1 2 4 8 16 + 13 -53 88 0 57 1 5 1 2 4 8 16 + 14 83 -24 0 1 1 5 1 2 4 8 16 + 15 24 41 0 66 1 5 1 2 4 8 16 + 16 17 21 0 37 1 5 1 2 4 8 16 + 17 42 96 0 51 1 5 1 2 4 8 16 + 18 -65 0 0 47 1 5 1 2 4 8 16 + 19 -47 -26 0 88 1 5 1 2 4 8 16 + 20 85 36 0 75 1 5 1 2 4 8 16 + 21 -35 -54 0 48 1 5 1 2 4 8 16 + 22 54 -21 0 40 1 5 1 2 4 8 16 + 23 64 -17 0 8 1 5 1 2 4 8 16 + 24 55 89 0 69 1 5 1 2 4 8 16 + 25 17 -25 0 93 1 5 1 2 4 8 16 + 26 -61 66 0 29 1 5 1 2 4 8 16 + 27 -61 26 0 5 1 5 1 2 4 8 16 + 28 17 -72 0 53 1 5 1 2 4 8 16 + 29 79 38 0 8 1 5 1 2 4 8 16 + 30 -62 -2 0 24 1 5 1 2 4 8 16 + 31 -90 -68 0 53 1 5 1 2 4 8 16 + 32 52 66 0 13 1 5 1 2 4 8 16 + 33 -54 -50 0 47 1 5 1 2 4 8 16 + 34 8 -84 0 57 1 5 1 2 4 8 16 + 35 37 -90 0 9 1 5 1 2 4 8 16 + 36 -83 49 0 74 1 5 1 2 4 8 16 + 37 35 -1 0 83 1 5 1 2 4 8 16 + 38 7 59 0 96 1 5 1 2 4 8 16 + 39 12 48 0 42 1 5 1 2 4 8 16 + 40 57 95 0 80 1 5 1 2 4 8 16 + 41 92 28 0 22 1 5 1 2 4 8 16 + 42 -3 97 0 56 1 5 1 2 4 8 16 + 43 -7 52 0 43 1 5 1 2 4 8 16 + 44 42 -15 0 12 1 5 1 2 4 8 16 + 45 77 -43 0 73 1 5 1 2 4 8 16 + 46 59 -49 0 32 1 5 1 2 4 8 16 + 47 25 91 0 8 1 5 1 2 4 8 16 + 48 69 -19 0 79 1 5 1 2 4 8 16 + 49 -82 -14 0 79 1 5 1 2 4 8 16 + 50 74 -70 0 4 1 5 1 2 4 8 16 + 51 69 59 0 14 1 5 1 2 4 8 16 + 52 29 33 0 17 1 5 1 2 4 8 16 + 53 -97 9 0 19 1 5 1 2 4 8 16 + 54 -58 9 0 44 1 5 1 2 4 8 16 + 55 28 93 0 5 1 5 1 2 4 8 16 + 56 7 73 0 37 1 5 1 2 4 8 16 + 57 -28 73 0 100 1 5 1 2 4 8 16 + 58 -76 55 0 62 1 5 1 2 4 8 16 + 59 41 42 0 90 1 5 1 2 4 8 16 + 60 92 40 0 57 1 5 1 2 4 8 16 + 61 -84 -29 0 44 1 5 1 2 4 8 16 + 62 -12 42 0 37 1 5 1 2 4 8 16 + 63 51 -45 0 80 1 5 1 2 4 8 16 + 64 -37 46 0 60 1 5 1 2 4 8 16 + 65 -97 35 0 95 1 5 1 2 4 8 16 + 66 14 89 0 56 1 5 1 2 4 8 16 + 67 60 58 0 56 1 5 1 2 4 8 16 + 68 -63 -75 0 9 1 5 1 2 4 8 16 + 69 -18 34 0 39 1 5 1 2 4 8 16 + 70 -46 -82 0 15 1 5 1 2 4 8 16 + 71 -86 -79 0 4 1 5 1 2 4 8 16 + 72 -43 -30 0 58 1 5 1 2 4 8 16 + 73 -44 7 0 73 1 5 1 2 4 8 16 + 74 -3 -20 0 5 1 5 1 2 4 8 16 + 75 36 41 0 12 1 5 1 2 4 8 16 + 76 -30 -94 0 3 1 5 1 2 4 8 16 + 77 79 -62 0 8 1 5 1 2 4 8 16 + 78 51 70 0 31 1 5 1 2 4 8 16 + 79 -61 -26 0 48 1 5 1 2 4 8 16 + 80 6 94 0 3 1 5 1 2 4 8 16 + 81 -19 -62 0 52 1 5 1 2 4 8 16 + 82 -20 51 0 99 1 5 1 2 4 8 16 + 83 -81 37 0 29 1 5 1 2 4 8 16 + 84 7 31 0 12 1 5 1 2 4 8 16 + 85 52 12 0 50 1 5 1 2 4 8 16 + 86 83 -91 0 98 1 5 1 2 4 8 16 + 87 -7 -92 0 4 1 5 1 2 4 8 16 + 88 82 -74 0 56 1 5 1 2 4 8 16 + 89 -70 85 0 24 1 5 1 2 4 8 16 + 90 -83 -30 0 33 1 5 1 2 4 8 16 + 91 71 -61 0 45 1 5 1 2 4 8 16 + 92 85 11 0 98 1 5 1 2 4 8 16 + 93 66 -48 0 4 1 5 1 2 4 8 16 + 94 78 -87 0 36 1 5 1 2 4 8 16 + 95 9 -79 0 72 1 5 1 2 4 8 16 + 96 -36 4 0 26 1 5 1 2 4 8 16 + 97 66 39 0 71 1 5 1 2 4 8 16 + 98 92 -17 0 84 1 5 1 2 4 8 16 + 99 -46 -79 0 21 1 5 1 2 4 8 16 +100 -30 -63 0 99 1 5 1 2 4 8 16 +101 -42 63 0 33 1 5 1 2 4 8 16 +102 20 42 0 84 1 5 1 2 4 8 16 +103 15 98 0 74 1 5 1 2 4 8 16 +104 1 -17 0 93 1 5 1 2 4 8 16 +105 64 20 0 25 1 5 1 2 4 8 16 +106 -96 85 0 39 1 5 1 2 4 8 16 +107 93 -29 0 42 1 5 1 2 4 8 16 +108 -40 -84 0 77 1 5 1 2 4 8 16 +109 86 35 0 68 1 5 1 2 4 8 16 +110 91 36 0 50 1 5 1 2 4 8 16 +111 62 -8 0 42 1 5 1 2 4 8 16 +112 -24 4 0 71 1 5 1 2 4 8 16 +113 11 96 0 85 1 5 1 2 4 8 16 +114 -53 62 0 78 1 5 1 2 4 8 16 +115 -28 -71 0 64 1 5 1 2 4 8 16 +116 7 -4 0 5 1 5 1 2 4 8 16 +117 95 -9 0 93 1 5 1 2 4 8 16 +118 -3 17 0 18 1 5 1 2 4 8 16 +119 53 -90 0 38 1 5 1 2 4 8 16 +120 58 -19 0 29 1 5 1 2 4 8 16 +121 -83 84 0 81 1 5 1 2 4 8 16 +122 -1 49 0 4 1 5 1 2 4 8 16 +123 -4 17 0 23 1 5 1 2 4 8 16 +124 -82 -3 0 11 1 5 1 2 4 8 16 +125 -43 47 0 86 1 5 1 2 4 8 16 +126 6 -6 0 2 1 5 1 2 4 8 16 +127 70 99 0 31 1 5 1 2 4 8 16 +128 68 -29 0 54 1 5 1 2 4 8 16 +129 -94 -30 0 87 1 5 1 2 4 8 16 +130 -94 -20 0 17 1 5 1 2 4 8 16 +131 -21 77 0 81 1 5 1 2 4 8 16 +132 64 37 0 72 1 5 1 2 4 8 16 +133 -70 -19 0 10 1 5 1 2 4 8 16 +134 88 65 0 50 1 5 1 2 4 8 16 +135 2 29 0 25 1 5 1 2 4 8 16 +136 33 57 0 71 1 5 1 2 4 8 16 +137 -70 6 0 85 1 5 1 2 4 8 16 +138 -38 -56 0 51 1 5 1 2 4 8 16 +139 -80 -95 0 29 1 5 1 2 4 8 16 +140 -5 -39 0 55 1 5 1 2 4 8 16 +141 8 -22 0 45 1 5 1 2 4 8 16 +142 -61 -76 0 100 1 5 1 2 4 8 16 +143 76 -22 0 38 1 5 1 2 4 8 16 +144 49 -71 0 11 1 5 1 2 4 8 16 +145 -30 -68 0 82 1 5 1 2 4 8 16 +146 1 34 0 50 1 5 1 2 4 8 16 +147 77 79 0 39 1 5 1 2 4 8 16 +148 -58 64 0 6 1 5 1 2 4 8 16 +149 82 -97 0 87 1 5 1 2 4 8 16 +150 -80 55 0 83 1 5 1 2 4 8 16 +151 81 -86 0 22 1 5 1 2 4 8 16 +152 39 -49 0 24 1 5 1 2 4 8 16 +153 -67 72 0 69 1 5 1 2 4 8 16 +154 -25 -89 0 97 1 5 1 2 4 8 16 +155 -44 -95 0 65 1 5 1 2 4 8 16 +156 32 -68 0 97 1 5 1 2 4 8 16 +157 -17 49 0 79 1 5 1 2 4 8 16 +158 93 49 0 79 1 5 1 2 4 8 16 +159 99 81 0 46 1 5 1 2 4 8 16 +160 10 -49 0 52 1 5 1 2 4 8 16 +161 63 -41 0 39 1 5 1 2 4 8 16 +162 38 39 0 94 1 5 1 2 4 8 16 +163 -28 39 0 97 1 5 1 2 4 8 16 +164 -2 -47 0 18 1 5 1 2 4 8 16 +165 38 8 0 3 1 5 1 2 4 8 16 +166 -42 -6 0 23 1 5 1 2 4 8 16 +167 -67 88 0 19 1 5 1 2 4 8 16 +168 19 93 0 40 1 5 1 2 4 8 16 +169 40 27 0 49 1 5 1 2 4 8 16 +170 -61 56 0 96 1 5 1 2 4 8 16 +171 43 33 0 58 1 5 1 2 4 8 16 +172 -18 -39 0 15 1 5 1 2 4 8 16 +173 -69 19 0 21 1 5 1 2 4 8 16 +174 75 -18 0 56 1 5 1 2 4 8 16 +175 31 85 0 67 1 5 1 2 4 8 16 +176 25 58 0 10 1 5 1 2 4 8 16 +177 -16 36 0 36 1 5 1 2 4 8 16 +178 91 15 0 84 1 5 1 2 4 8 16 +179 60 -39 0 59 1 5 1 2 4 8 16 +180 49 -47 0 85 1 5 1 2 4 8 16 +181 42 33 0 60 1 5 1 2 4 8 16 +182 16 -81 0 33 1 5 1 2 4 8 16 +183 -78 53 0 62 1 5 1 2 4 8 16 +184 53 -80 0 70 1 5 1 2 4 8 16 +185 -46 -26 0 79 1 5 1 2 4 8 16 +186 -25 -54 0 98 1 5 1 2 4 8 16 +187 69 -46 0 99 1 5 1 2 4 8 16 +188 0 -78 0 18 1 5 1 2 4 8 16 +189 -84 74 0 55 1 5 1 2 4 8 16 +190 -16 16 0 75 1 5 1 2 4 8 16 +191 -63 -14 0 94 1 5 1 2 4 8 16 +192 51 -77 0 89 1 5 1 2 4 8 16 +193 -39 61 0 13 1 5 1 2 4 8 16 +194 5 97 0 19 1 5 1 2 4 8 16 +195 -55 39 0 19 1 5 1 2 4 8 16 +196 70 -14 0 90 1 5 1 2 4 8 16 +197 0 95 0 35 1 5 1 2 4 8 16 +198 -45 7 0 76 1 5 1 2 4 8 16 +199 38 -24 0 3 1 5 1 2 4 8 16 +200 50 -37 0 11 1 5 1 2 4 8 16 +201 59 71 0 98 1 5 1 2 4 8 16 +202 -73 -96 0 92 1 5 1 2 4 8 16 +203 -29 72 0 1 1 5 1 2 4 8 16 +204 -47 12 0 2 1 5 1 2 4 8 16 +205 -88 -61 0 63 1 5 1 2 4 8 16 +206 -88 36 0 57 1 5 1 2 4 8 16 +207 -46 -3 0 50 1 5 1 2 4 8 16 +208 26 -37 0 19 1 5 1 2 4 8 16 +209 -39 -67 0 24 1 5 1 2 4 8 16 +210 92 27 0 14 1 5 1 2 4 8 16 +211 -80 -31 0 18 1 5 1 2 4 8 16 +212 93 -50 0 77 1 5 1 2 4 8 16 +213 -20 -5 0 28 1 5 1 2 4 8 16 +214 -22 73 0 72 1 5 1 2 4 8 16 +215 -4 -7 0 49 1 5 1 2 4 8 16 +216 54 -48 0 58 1 5 1 2 4 8 16 +217 -70 39 0 84 1 5 1 2 4 8 16 +218 54 -82 0 58 1 5 1 2 4 8 16 +219 29 41 0 41 1 5 1 2 4 8 16 +220 -87 51 0 98 1 5 1 2 4 8 16 +221 -96 -36 0 77 1 5 1 2 4 8 16 +222 49 8 0 57 1 5 1 2 4 8 16 +223 -5 54 0 39 1 5 1 2 4 8 16 +224 -26 43 0 99 1 5 1 2 4 8 16 +225 -11 60 0 83 1 5 1 2 4 8 16 +226 40 61 0 54 1 5 1 2 4 8 16 +227 82 35 0 86 1 5 1 2 4 8 16 +228 -92 12 0 2 1 5 1 2 4 8 16 +229 -93 -86 0 14 1 5 1 2 4 8 16 +230 -66 63 0 42 1 5 1 2 4 8 16 +231 -72 -87 0 14 1 5 1 2 4 8 16 +232 -57 -84 0 55 1 5 1 2 4 8 16 +233 23 52 0 2 1 5 1 2 4 8 16 +234 -56 -62 0 18 1 5 1 2 4 8 16 +235 -19 59 0 17 1 5 1 2 4 8 16 +236 63 -14 0 22 1 5 1 2 4 8 16 +237 -13 38 0 28 1 5 1 2 4 8 16 +238 -19 87 0 3 1 5 1 2 4 8 16 +239 44 -84 0 96 1 5 1 2 4 8 16 +240 98 -17 0 53 1 5 1 2 4 8 16 +241 -16 62 0 15 1 5 1 2 4 8 16 +242 3 66 0 36 1 5 1 2 4 8 16 +243 26 22 0 98 1 5 1 2 4 8 16 +244 -38 -81 0 78 1 5 1 2 4 8 16 +245 70 -80 0 92 1 5 1 2 4 8 16 +246 17 -35 0 65 1 5 1 2 4 8 16 +247 96 -83 0 64 1 5 1 2 4 8 16 +248 -77 80 0 43 1 5 1 2 4 8 16 +249 -14 44 0 50 1 5 1 2 4 8 16 +250 70 0 0 0 0 0 +251 40 80 0 0 0 0 +252 40 -80 0 0 0 0 +253 -60 20 0 0 0 0 +254 -60 -20 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p11.res b/jsprit-instances/instances/cordeau/p11.res new file mode 100644 index 00000000..38db8e77 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p11.res @@ -0,0 +1,27 @@ +3554.18 +1 1 140.19 472 0 222 165 6 16 243 52 181 171 169 85 0 +1 2 84.20 327 0 92 109 20 227 0 +1 3 131.64 482 0 105 132 97 29 158 60 110 41 210 178 0 +1 4 119.29 495 0 48 128 179 161 46 63 200 22 120 23 236 111 0 +1 5 190.11 474 0 44 199 208 246 25 141 104 74 215 126 116 37 0 +1 6 96.14 457 0 117 240 98 107 14 143 174 196 0 +2 1 164.38 496 0 10 238 131 214 57 203 11 235 241 225 242 0 +2 2 117.60 497 0 176 233 102 15 219 75 162 59 226 32 78 0 +2 3 163.16 483 0 24 40 127 147 159 134 51 67 201 0 +2 4 177.09 484 0 136 39 84 135 146 237 62 122 43 223 38 56 0 +2 5 112.21 499 0 175 66 80 197 42 194 113 103 168 47 55 17 0 +3 1 142.21 497 0 50 88 247 149 86 151 94 245 119 0 +3 2 174.80 488 0 156 160 7 164 140 172 186 81 4 95 0 +3 3 33.10 313 0 192 184 218 239 0 +3 4 151.32 484 0 152 180 216 93 187 45 212 77 91 144 0 +3 5 193.99 494 0 28 188 244 108 155 76 154 87 34 182 35 0 +4 1 130.73 334 0 54 137 124 53 228 65 206 173 0 +4 2 95.93 492 0 83 36 220 150 183 58 217 0 +4 3 116.47 499 0 163 224 82 157 249 177 69 0 +4 4 142.60 445 0 204 73 96 112 213 8 3 118 123 190 0 +4 5 198.03 487 0 27 230 9 153 13 167 89 248 121 106 189 0 +4 6 124.44 492 0 125 64 193 101 114 148 26 170 2 195 0 +5 1 97.00 468 0 5 133 12 49 130 129 221 61 90 211 79 0 +5 2 230.26 493 0 205 31 71 229 1 139 202 231 232 70 99 142 68 234 0 +5 3 94.46 481 0 191 18 30 198 207 166 185 19 0 +5 4 132.83 473 0 72 21 138 100 145 115 209 33 0 diff --git a/jsprit-instances/instances/cordeau/p12 b/jsprit-instances/instances/cordeau/p12 new file mode 100644 index 00000000..2a354d6a --- /dev/null +++ b/jsprit-instances/instances/cordeau/p12 @@ -0,0 +1,85 @@ +2 5 80 2 +300 60 +300 60 + 1 -10 -10 0 12 1 2 1 2 + 2 -10 0 0 12 1 2 1 2 + 3 -10 10 0 12 1 2 1 2 + 4 0 -10 0 12 1 2 1 2 + 5 0 10 0 12 1 2 1 2 + 6 10 -10 0 12 1 2 1 2 + 7 10 0 0 12 1 2 1 2 + 8 10 10 0 12 1 2 1 2 + 9 -20 -20 0 8 1 2 1 2 +10 -20 0 0 8 1 2 1 2 +11 -20 20 0 8 1 2 1 2 +12 0 -20 0 8 1 2 1 2 +13 0 20 0 8 1 2 1 2 +14 20 -20 0 8 1 2 1 2 +15 20 0 0 8 1 2 1 2 +16 20 20 0 8 1 2 1 2 +17 -30 -30 0 4 1 2 1 2 +18 -30 0 0 4 1 2 1 2 +19 -30 30 0 4 1 2 1 2 +20 0 -30 0 4 1 2 1 2 +21 0 30 0 4 1 2 1 2 +22 30 -30 0 4 1 2 1 2 +23 30 0 0 4 1 2 1 2 +24 30 30 0 4 1 2 1 2 +25 -40 -40 0 2 1 2 1 2 +26 -40 0 0 2 1 2 1 2 +27 -40 40 0 2 1 2 1 2 +28 0 -40 0 2 1 2 1 2 +29 0 40 0 2 1 2 1 2 +30 40 -40 0 2 1 2 1 2 +31 40 0 0 2 1 2 1 2 +32 40 40 0 2 1 2 1 2 +33 -50 -50 0 1 1 2 1 2 +34 -50 0 0 1 1 2 1 2 +35 -50 50 0 1 1 2 1 2 +36 0 -50 0 1 1 2 1 2 +37 0 50 0 1 1 2 1 2 +38 50 -50 0 1 1 2 1 2 +39 50 0 0 1 1 2 1 2 +40 50 50 0 1 1 2 1 2 +41 100 -10 0 12 1 2 1 2 +42 100 0 0 12 1 2 1 2 +43 100 10 0 12 1 2 1 2 +44 110 -10 0 12 1 2 1 2 +45 110 10 0 12 1 2 1 2 +46 120 -10 0 12 1 2 1 2 +47 120 0 0 12 1 2 1 2 +48 120 10 0 12 1 2 1 2 +49 90 -20 0 8 1 2 1 2 +50 90 0 0 8 1 2 1 2 +51 90 20 0 8 1 2 1 2 +52 110 -20 0 8 1 2 1 2 +53 110 20 0 8 1 2 1 2 +54 130 -20 0 8 1 2 1 2 +55 130 0 0 8 1 2 1 2 +56 130 20 0 8 1 2 1 2 +57 80 -30 0 4 1 2 1 2 +58 80 0 0 4 1 2 1 2 +59 80 30 0 4 1 2 1 2 +60 110 -30 0 4 1 2 1 2 +61 110 30 0 4 1 2 1 2 +62 140 -30 0 4 1 2 1 2 +63 140 0 0 4 1 2 1 2 +64 140 30 0 4 1 2 1 2 +65 70 -40 0 2 1 2 1 2 +66 70 0 0 2 1 2 1 2 +67 70 40 0 2 1 2 1 2 +68 110 -40 0 2 1 2 1 2 +69 110 40 0 2 1 2 1 2 +70 150 -40 0 2 1 2 1 2 +71 150 0 0 2 1 2 1 2 +72 150 40 0 2 1 2 1 2 +73 60 -50 0 1 1 2 1 2 +74 60 0 0 1 1 2 1 2 +75 60 50 0 1 1 2 1 2 +76 110 -50 0 1 1 2 1 2 +77 110 50 0 1 1 2 1 2 +78 160 -50 0 1 1 2 1 2 +79 160 0 0 1 1 2 1 2 +80 160 50 0 1 1 2 1 2 +81 0 0 0 0 0 0 +82 110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p12.res b/jsprit-instances/instances/cordeau/p12.res new file mode 100644 index 00000000..02684db0 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p12.res @@ -0,0 +1,9 @@ +1318.95 +1 1 128.48 51 0 4 12 20 28 36 22 14 6 0 +1 2 189.57 57 0 7 15 23 31 39 67 75 40 32 24 16 8 0 +1 3 170.71 54 0 5 13 21 29 37 35 27 19 11 3 0 +1 4 170.71 54 0 1 9 17 25 33 34 26 18 10 2 0 +2 1 128.48 51 0 45 53 61 69 77 59 51 43 0 +2 2 170.71 54 0 47 55 63 71 79 80 72 64 56 48 0 +2 3 189.57 57 0 42 50 58 66 74 30 38 73 65 57 49 41 0 +2 4 170.71 54 0 46 54 62 70 78 76 68 60 52 44 0 diff --git a/jsprit-instances/instances/cordeau/p13 b/jsprit-instances/instances/cordeau/p13 new file mode 100644 index 00000000..5febde97 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p13 @@ -0,0 +1,85 @@ +2 5 80 2 +200 60 +200 60 + 1 -10 -10 0 12 1 2 1 2 + 2 -10 0 0 12 1 2 1 2 + 3 -10 10 0 12 1 2 1 2 + 4 0 -10 0 12 1 2 1 2 + 5 0 10 0 12 1 2 1 2 + 6 10 -10 0 12 1 2 1 2 + 7 10 0 0 12 1 2 1 2 + 8 10 10 0 12 1 2 1 2 + 9 -20 -20 0 8 1 2 1 2 +10 -20 0 0 8 1 2 1 2 +11 -20 20 0 8 1 2 1 2 +12 0 -20 0 8 1 2 1 2 +13 0 20 0 8 1 2 1 2 +14 20 -20 0 8 1 2 1 2 +15 20 0 0 8 1 2 1 2 +16 20 20 0 8 1 2 1 2 +17 -30 -30 0 4 1 2 1 2 +18 -30 0 0 4 1 2 1 2 +19 -30 30 0 4 1 2 1 2 +20 0 -30 0 4 1 2 1 2 +21 0 30 0 4 1 2 1 2 +22 30 -30 0 4 1 2 1 2 +23 30 0 0 4 1 2 1 2 +24 30 30 0 4 1 2 1 2 +25 -40 -40 0 2 1 2 1 2 +26 -40 0 0 2 1 2 1 2 +27 -40 40 0 2 1 2 1 2 +28 0 -40 0 2 1 2 1 2 +29 0 40 0 2 1 2 1 2 +30 40 -40 0 2 1 2 1 2 +31 40 0 0 2 1 2 1 2 +32 40 40 0 2 1 2 1 2 +33 -50 -50 0 1 1 2 1 2 +34 -50 0 0 1 1 2 1 2 +35 -50 50 0 1 1 2 1 2 +36 0 -50 0 1 1 2 1 2 +37 0 50 0 1 1 2 1 2 +38 50 -50 0 1 1 2 1 2 +39 50 0 0 1 1 2 1 2 +40 50 50 0 1 1 2 1 2 +41 100 -10 0 12 1 2 1 2 +42 100 0 0 12 1 2 1 2 +43 100 10 0 12 1 2 1 2 +44 110 -10 0 12 1 2 1 2 +45 110 10 0 12 1 2 1 2 +46 120 -10 0 12 1 2 1 2 +47 120 0 0 12 1 2 1 2 +48 120 10 0 12 1 2 1 2 +49 90 -20 0 8 1 2 1 2 +50 90 0 0 8 1 2 1 2 +51 90 20 0 8 1 2 1 2 +52 110 -20 0 8 1 2 1 2 +53 110 20 0 8 1 2 1 2 +54 130 -20 0 8 1 2 1 2 +55 130 0 0 8 1 2 1 2 +56 130 20 0 8 1 2 1 2 +57 80 -30 0 4 1 2 1 2 +58 80 0 0 4 1 2 1 2 +59 80 30 0 4 1 2 1 2 +60 110 -30 0 4 1 2 1 2 +61 110 30 0 4 1 2 1 2 +62 140 -30 0 4 1 2 1 2 +63 140 0 0 4 1 2 1 2 +64 140 30 0 4 1 2 1 2 +65 70 -40 0 2 1 2 1 2 +66 70 0 0 2 1 2 1 2 +67 70 40 0 2 1 2 1 2 +68 110 -40 0 2 1 2 1 2 +69 110 40 0 2 1 2 1 2 +70 150 -40 0 2 1 2 1 2 +71 150 0 0 2 1 2 1 2 +72 150 40 0 2 1 2 1 2 +73 60 -50 0 1 1 2 1 2 +74 60 0 0 1 1 2 1 2 +75 60 50 0 1 1 2 1 2 +76 110 -50 0 1 1 2 1 2 +77 110 50 0 1 1 2 1 2 +78 160 -50 0 1 1 2 1 2 +79 160 0 0 1 1 2 1 2 +80 160 50 0 1 1 2 1 2 +81 0 0 0 0 0 0 +82 110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p13.res b/jsprit-instances/instances/cordeau/p13.res new file mode 100644 index 00000000..75468ac6 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p13.res @@ -0,0 +1,9 @@ +1318.95 +1 1 170.71 54 0 3 11 19 27 35 34 26 18 10 2 0 +1 2 128.48 51 0 8 16 24 37 29 21 13 5 0 +1 3 189.57 57 0 7 15 23 31 39 65 73 38 30 22 14 6 0 +1 4 170.71 54 0 1 9 17 25 33 36 28 20 12 4 0 +2 1 128.48 51 0 41 49 57 76 68 60 52 44 0 +2 2 170.71 54 0 45 53 61 69 77 80 72 64 56 48 0 +2 3 189.57 57 0 42 50 58 66 74 32 40 75 67 59 51 43 0 +2 4 170.71 54 0 47 55 63 71 79 78 70 62 54 46 0 diff --git a/jsprit-instances/instances/cordeau/p14 b/jsprit-instances/instances/cordeau/p14 new file mode 100644 index 00000000..f44dbb4f --- /dev/null +++ b/jsprit-instances/instances/cordeau/p14 @@ -0,0 +1,85 @@ +2 5 80 2 +180 60 +180 60 + 1 -10 -10 0 12 1 2 1 2 + 2 -10 0 0 12 1 2 1 2 + 3 -10 10 0 12 1 2 1 2 + 4 0 -10 0 12 1 2 1 2 + 5 0 10 0 12 1 2 1 2 + 6 10 -10 0 12 1 2 1 2 + 7 10 0 0 12 1 2 1 2 + 8 10 10 0 12 1 2 1 2 + 9 -20 -20 0 8 1 2 1 2 +10 -20 0 0 8 1 2 1 2 +11 -20 20 0 8 1 2 1 2 +12 0 -20 0 8 1 2 1 2 +13 0 20 0 8 1 2 1 2 +14 20 -20 0 8 1 2 1 2 +15 20 0 0 8 1 2 1 2 +16 20 20 0 8 1 2 1 2 +17 -30 -30 0 4 1 2 1 2 +18 -30 0 0 4 1 2 1 2 +19 -30 30 0 4 1 2 1 2 +20 0 -30 0 4 1 2 1 2 +21 0 30 0 4 1 2 1 2 +22 30 -30 0 4 1 2 1 2 +23 30 0 0 4 1 2 1 2 +24 30 30 0 4 1 2 1 2 +25 -40 -40 0 2 1 2 1 2 +26 -40 0 0 2 1 2 1 2 +27 -40 40 0 2 1 2 1 2 +28 0 -40 0 2 1 2 1 2 +29 0 40 0 2 1 2 1 2 +30 40 -40 0 2 1 2 1 2 +31 40 0 0 2 1 2 1 2 +32 40 40 0 2 1 2 1 2 +33 -50 -50 0 1 1 2 1 2 +34 -50 0 0 1 1 2 1 2 +35 -50 50 0 1 1 2 1 2 +36 0 -50 0 1 1 2 1 2 +37 0 50 0 1 1 2 1 2 +38 50 -50 0 1 1 2 1 2 +39 50 0 0 1 1 2 1 2 +40 50 50 0 1 1 2 1 2 +41 100 -10 0 12 1 2 1 2 +42 100 0 0 12 1 2 1 2 +43 100 10 0 12 1 2 1 2 +44 110 -10 0 12 1 2 1 2 +45 110 10 0 12 1 2 1 2 +46 120 -10 0 12 1 2 1 2 +47 120 0 0 12 1 2 1 2 +48 120 10 0 12 1 2 1 2 +49 90 -20 0 8 1 2 1 2 +50 90 0 0 8 1 2 1 2 +51 90 20 0 8 1 2 1 2 +52 110 -20 0 8 1 2 1 2 +53 110 20 0 8 1 2 1 2 +54 130 -20 0 8 1 2 1 2 +55 130 0 0 8 1 2 1 2 +56 130 20 0 8 1 2 1 2 +57 80 -30 0 4 1 2 1 2 +58 80 0 0 4 1 2 1 2 +59 80 30 0 4 1 2 1 2 +60 110 -30 0 4 1 2 1 2 +61 110 30 0 4 1 2 1 2 +62 140 -30 0 4 1 2 1 2 +63 140 0 0 4 1 2 1 2 +64 140 30 0 4 1 2 1 2 +65 70 -40 0 2 1 2 1 2 +66 70 0 0 2 1 2 1 2 +67 70 40 0 2 1 2 1 2 +68 110 -40 0 2 1 2 1 2 +69 110 40 0 2 1 2 1 2 +70 150 -40 0 2 1 2 1 2 +71 150 0 0 2 1 2 1 2 +72 150 40 0 2 1 2 1 2 +73 60 -50 0 1 1 2 1 2 +74 60 0 0 1 1 2 1 2 +75 60 50 0 1 1 2 1 2 +76 110 -50 0 1 1 2 1 2 +77 110 50 0 1 1 2 1 2 +78 160 -50 0 1 1 2 1 2 +79 160 0 0 1 1 2 1 2 +80 160 50 0 1 1 2 1 2 +81 0 0 0 0 0 0 +82 110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p14.res b/jsprit-instances/instances/cordeau/p14.res new file mode 100644 index 00000000..1524252d --- /dev/null +++ b/jsprit-instances/instances/cordeau/p14.res @@ -0,0 +1,9 @@ +1360.12 +1 1 170.71 54 0 4 12 20 28 36 33 25 17 9 1 0 +1 2 174.56 54 0 6 14 22 30 38 73 31 23 15 7 0 +1 3 170.71 54 0 3 11 19 27 35 34 26 18 10 2 0 +1 4 170.71 54 0 8 16 24 32 40 37 29 21 13 5 0 +2 1 170.71 54 0 48 56 64 72 80 79 71 63 55 47 0 +2 2 161.29 54 0 42 50 58 66 74 39 65 57 49 41 0 +2 3 170.71 54 0 43 51 59 67 75 77 69 61 53 45 0 +2 4 170.71 54 0 44 52 60 68 76 78 70 62 54 46 0 diff --git a/jsprit-instances/instances/cordeau/p15 b/jsprit-instances/instances/cordeau/p15 new file mode 100644 index 00000000..c4a2530d --- /dev/null +++ b/jsprit-instances/instances/cordeau/p15 @@ -0,0 +1,169 @@ +2 5 160 4 +0 60 +0 60 +0 60 +0 60 + 1 -10 -10 0 12 1 4 1 2 4 8 + 2 -10 0 0 12 1 4 1 2 4 8 + 3 -10 10 0 12 1 4 1 2 4 8 + 4 0 -10 0 12 1 4 1 2 4 8 + 5 0 10 0 12 1 4 1 2 4 8 + 6 10 -10 0 12 1 4 1 2 4 8 + 7 10 0 0 12 1 4 1 2 4 8 + 8 10 10 0 12 1 4 1 2 4 8 + 9 -20 -20 0 8 1 4 1 2 4 8 + 10 -20 0 0 8 1 4 1 2 4 8 + 11 -20 20 0 8 1 4 1 2 4 8 + 12 0 -20 0 8 1 4 1 2 4 8 + 13 0 20 0 8 1 4 1 2 4 8 + 14 20 -20 0 8 1 4 1 2 4 8 + 15 20 0 0 8 1 4 1 2 4 8 + 16 20 20 0 8 1 4 1 2 4 8 + 17 -30 -30 0 4 1 4 1 2 4 8 + 18 -30 0 0 4 1 4 1 2 4 8 + 19 -30 30 0 4 1 4 1 2 4 8 + 20 0 -30 0 4 1 4 1 2 4 8 + 21 0 30 0 4 1 4 1 2 4 8 + 22 30 -30 0 4 1 4 1 2 4 8 + 23 30 0 0 4 1 4 1 2 4 8 + 24 30 30 0 4 1 4 1 2 4 8 + 25 -40 -40 0 2 1 4 1 2 4 8 + 26 -40 0 0 2 1 4 1 2 4 8 + 27 -40 40 0 2 1 4 1 2 4 8 + 28 0 -40 0 2 1 4 1 2 4 8 + 29 0 40 0 2 1 4 1 2 4 8 + 30 40 -40 0 2 1 4 1 2 4 8 + 31 40 0 0 2 1 4 1 2 4 8 + 32 40 40 0 2 1 4 1 2 4 8 + 33 -50 -50 0 1 1 4 1 2 4 8 + 34 -50 0 0 1 1 4 1 2 4 8 + 35 -50 50 0 1 1 4 1 2 4 8 + 36 0 -50 0 1 1 4 1 2 4 8 + 37 0 50 0 1 1 4 1 2 4 8 + 38 50 -50 0 1 1 4 1 2 4 8 + 39 50 0 0 1 1 4 1 2 4 8 + 40 50 50 0 1 1 4 1 2 4 8 + 41 100 -10 0 12 1 4 1 2 4 8 + 42 100 0 0 12 1 4 1 2 4 8 + 43 100 10 0 12 1 4 1 2 4 8 + 44 110 -10 0 12 1 4 1 2 4 8 + 45 110 10 0 12 1 4 1 2 4 8 + 46 120 -10 0 12 1 4 1 2 4 8 + 47 120 0 0 12 1 4 1 2 4 8 + 48 120 10 0 12 1 4 1 2 4 8 + 49 90 -20 0 8 1 4 1 2 4 8 + 50 90 0 0 8 1 4 1 2 4 8 + 51 90 20 0 8 1 4 1 2 4 8 + 52 110 -20 0 8 1 4 1 2 4 8 + 53 110 20 0 8 1 4 1 2 4 8 + 54 130 -20 0 8 1 4 1 2 4 8 + 55 130 0 0 8 1 4 1 2 4 8 + 56 130 20 0 8 1 4 1 2 4 8 + 57 80 -30 0 4 1 4 1 2 4 8 + 58 80 0 0 4 1 4 1 2 4 8 + 59 80 30 0 4 1 4 1 2 4 8 + 60 110 -30 0 4 1 4 1 2 4 8 + 61 110 30 0 4 1 4 1 2 4 8 + 62 140 -30 0 4 1 4 1 2 4 8 + 63 140 0 0 4 1 4 1 2 4 8 + 64 140 30 0 4 1 4 1 2 4 8 + 65 70 -40 0 2 1 4 1 2 4 8 + 66 70 0 0 2 1 4 1 2 4 8 + 67 70 40 0 2 1 4 1 2 4 8 + 68 110 -40 0 2 1 4 1 2 4 8 + 69 110 40 0 2 1 4 1 2 4 8 + 70 150 -40 0 2 1 4 1 2 4 8 + 71 150 0 0 2 1 4 1 2 4 8 + 72 150 40 0 2 1 4 1 2 4 8 + 73 60 -50 0 1 1 4 1 2 4 8 + 74 60 0 0 1 1 4 1 2 4 8 + 75 60 50 0 1 1 4 1 2 4 8 + 76 110 -50 0 1 1 4 1 2 4 8 + 77 110 50 0 1 1 4 1 2 4 8 + 78 160 -50 0 1 1 4 1 2 4 8 + 79 160 0 0 1 1 4 1 2 4 8 + 80 160 50 0 1 1 4 1 2 4 8 + 81 100 100 0 12 1 4 1 2 4 8 + 82 100 110 0 12 1 4 1 2 4 8 + 83 100 120 0 12 1 4 1 2 4 8 + 84 110 100 0 12 1 4 1 2 4 8 + 85 110 120 0 12 1 4 1 2 4 8 + 86 120 100 0 12 1 4 1 2 4 8 + 87 120 110 0 12 1 4 1 2 4 8 + 88 120 120 0 12 1 4 1 2 4 8 + 89 90 90 0 8 1 4 1 2 4 8 + 90 90 110 0 8 1 4 1 2 4 8 + 91 90 130 0 8 1 4 1 2 4 8 + 92 110 90 0 8 1 4 1 2 4 8 + 93 110 130 0 8 1 4 1 2 4 8 + 94 130 90 0 8 1 4 1 2 4 8 + 95 130 110 0 8 1 4 1 2 4 8 + 96 130 130 0 8 1 4 1 2 4 8 + 97 80 80 0 4 1 4 1 2 4 8 + 98 80 110 0 4 1 4 1 2 4 8 + 99 80 140 0 4 1 4 1 2 4 8 +100 110 80 0 4 1 4 1 2 4 8 +101 110 140 0 4 1 4 1 2 4 8 +102 140 80 0 4 1 4 1 2 4 8 +103 140 110 0 4 1 4 1 2 4 8 +104 140 140 0 4 1 4 1 2 4 8 +105 70 70 0 2 1 4 1 2 4 8 +106 70 110 0 2 1 4 1 2 4 8 +107 70 150 0 2 1 4 1 2 4 8 +108 110 70 0 2 1 4 1 2 4 8 +109 110 150 0 2 1 4 1 2 4 8 +110 150 70 0 2 1 4 1 2 4 8 +111 150 110 0 2 1 4 1 2 4 8 +112 150 150 0 2 1 4 1 2 4 8 +113 60 60 0 1 1 4 1 2 4 8 +114 60 110 0 1 1 4 1 2 4 8 +115 60 160 0 1 1 4 1 2 4 8 +116 110 60 0 1 1 4 1 2 4 8 +117 110 160 0 1 1 4 1 2 4 8 +118 160 60 0 1 1 4 1 2 4 8 +119 160 110 0 1 1 4 1 2 4 8 +120 160 160 0 1 1 4 1 2 4 8 +121 -10 100 0 12 1 4 1 2 4 8 +122 -10 110 0 12 1 4 1 2 4 8 +123 -10 120 0 12 1 4 1 2 4 8 +124 0 100 0 12 1 4 1 2 4 8 +125 0 120 0 12 1 4 1 2 4 8 +126 10 100 0 12 1 4 1 2 4 8 +127 10 110 0 12 1 4 1 2 4 8 +128 10 120 0 12 1 4 1 2 4 8 +129 -20 90 0 8 1 4 1 2 4 8 +130 -20 110 0 8 1 4 1 2 4 8 +131 -20 130 0 8 1 4 1 2 4 8 +132 0 90 0 8 1 4 1 2 4 8 +133 0 130 0 8 1 4 1 2 4 8 +134 20 90 0 8 1 4 1 2 4 8 +135 20 110 0 8 1 4 1 2 4 8 +136 20 130 0 8 1 4 1 2 4 8 +137 -30 80 0 4 1 4 1 2 4 8 +138 -30 110 0 4 1 4 1 2 4 8 +139 -30 140 0 4 1 4 1 2 4 8 +140 0 80 0 4 1 4 1 2 4 8 +141 0 140 0 4 1 4 1 2 4 8 +142 30 80 0 4 1 4 1 2 4 8 +143 30 110 0 4 1 4 1 2 4 8 +144 30 140 0 4 1 4 1 2 4 8 +145 -40 70 0 2 1 4 1 2 4 8 +146 -40 110 0 2 1 4 1 2 4 8 +147 -40 150 0 2 1 4 1 2 4 8 +148 0 70 0 2 1 4 1 2 4 8 +149 0 150 0 2 1 4 1 2 4 8 +150 40 70 0 2 1 4 1 2 4 8 +151 40 110 0 2 1 4 1 2 4 8 +152 40 150 0 2 1 4 1 2 4 8 +153 -50 60 0 1 1 4 1 2 4 8 +154 -50 110 0 1 1 4 1 2 4 8 +155 -50 160 0 1 1 4 1 2 4 8 +156 0 60 0 1 1 4 1 2 4 8 +157 0 160 0 1 1 4 1 2 4 8 +158 50 60 0 1 1 4 1 2 4 8 +159 50 110 0 1 1 4 1 2 4 8 +160 50 160 0 1 1 4 1 2 4 8 +161 0 0 0 0 0 0 +162 110 0 0 0 0 0 +163 110 110 0 0 0 0 +164 0 110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p15.res b/jsprit-instances/instances/cordeau/p15.res new file mode 100644 index 00000000..b1914786 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p15.res @@ -0,0 +1,17 @@ +2505.42 +1 1 147.80 53 0 3 11 19 27 34 26 18 10 2 0 +1 2 170.71 54 0 1 9 17 25 33 36 28 20 12 4 0 +1 3 233.14 60 0 15 23 31 39 74 66 58 50 49 57 65 73 38 30 22 14 0 +1 4 54.14 48 0 6 7 8 5 0 +2 1 233.14 60 0 53 61 69 77 116 108 100 92 89 97 105 113 75 67 59 51 0 +2 2 54.14 48 0 41 42 43 45 0 +2 3 188.93 55 0 48 56 64 72 118 80 79 71 63 55 47 0 +2 4 170.71 54 0 46 54 62 70 78 76 68 60 52 44 0 +3 1 147.80 53 0 86 94 102 110 119 111 103 95 87 0 +3 2 54.14 48 0 83 82 81 84 0 +3 3 170.71 54 0 85 93 101 109 117 120 112 104 96 88 0 +3 4 233.14 60 0 90 98 106 114 159 151 143 135 136 144 152 160 115 107 99 91 0 +4 1 54.14 48 0 124 126 127 128 0 +4 2 233.14 60 0 132 140 148 156 37 29 21 13 16 24 32 40 158 150 142 134 0 +4 3 170.71 54 0 123 131 139 147 155 157 149 141 133 125 0 +4 4 188.93 55 0 121 129 137 145 35 153 154 146 138 130 122 0 diff --git a/jsprit-instances/instances/cordeau/p16 b/jsprit-instances/instances/cordeau/p16 new file mode 100644 index 00000000..fdced944 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p16 @@ -0,0 +1,169 @@ +2 5 160 4 +200 60 +200 60 +200 60 +200 60 + 1 -10 -10 0 12 1 4 1 2 4 8 + 2 -10 0 0 12 1 4 1 2 4 8 + 3 -10 10 0 12 1 4 1 2 4 8 + 4 0 -10 0 12 1 4 1 2 4 8 + 5 0 10 0 12 1 4 1 2 4 8 + 6 10 -10 0 12 1 4 1 2 4 8 + 7 10 0 0 12 1 4 1 2 4 8 + 8 10 10 0 12 1 4 1 2 4 8 + 9 -20 -20 0 8 1 4 1 2 4 8 + 10 -20 0 0 8 1 4 1 2 4 8 + 11 -20 20 0 8 1 4 1 2 4 8 + 12 0 -20 0 8 1 4 1 2 4 8 + 13 0 20 0 8 1 4 1 2 4 8 + 14 20 -20 0 8 1 4 1 2 4 8 + 15 20 0 0 8 1 4 1 2 4 8 + 16 20 20 0 8 1 4 1 2 4 8 + 17 -30 -30 0 4 1 4 1 2 4 8 + 18 -30 0 0 4 1 4 1 2 4 8 + 19 -30 30 0 4 1 4 1 2 4 8 + 20 0 -30 0 4 1 4 1 2 4 8 + 21 0 30 0 4 1 4 1 2 4 8 + 22 30 -30 0 4 1 4 1 2 4 8 + 23 30 0 0 4 1 4 1 2 4 8 + 24 30 30 0 4 1 4 1 2 4 8 + 25 -40 -40 0 2 1 4 1 2 4 8 + 26 -40 0 0 2 1 4 1 2 4 8 + 27 -40 40 0 2 1 4 1 2 4 8 + 28 0 -40 0 2 1 4 1 2 4 8 + 29 0 40 0 2 1 4 1 2 4 8 + 30 40 -40 0 2 1 4 1 2 4 8 + 31 40 0 0 2 1 4 1 2 4 8 + 32 40 40 0 2 1 4 1 2 4 8 + 33 -50 -50 0 1 1 4 1 2 4 8 + 34 -50 0 0 1 1 4 1 2 4 8 + 35 -50 50 0 1 1 4 1 2 4 8 + 36 0 -50 0 1 1 4 1 2 4 8 + 37 0 50 0 1 1 4 1 2 4 8 + 38 50 -50 0 1 1 4 1 2 4 8 + 39 50 0 0 1 1 4 1 2 4 8 + 40 50 50 0 1 1 4 1 2 4 8 + 41 100 -10 0 12 1 4 1 2 4 8 + 42 100 0 0 12 1 4 1 2 4 8 + 43 100 10 0 12 1 4 1 2 4 8 + 44 110 -10 0 12 1 4 1 2 4 8 + 45 110 10 0 12 1 4 1 2 4 8 + 46 120 -10 0 12 1 4 1 2 4 8 + 47 120 0 0 12 1 4 1 2 4 8 + 48 120 10 0 12 1 4 1 2 4 8 + 49 90 -20 0 8 1 4 1 2 4 8 + 50 90 0 0 8 1 4 1 2 4 8 + 51 90 20 0 8 1 4 1 2 4 8 + 52 110 -20 0 8 1 4 1 2 4 8 + 53 110 20 0 8 1 4 1 2 4 8 + 54 130 -20 0 8 1 4 1 2 4 8 + 55 130 0 0 8 1 4 1 2 4 8 + 56 130 20 0 8 1 4 1 2 4 8 + 57 80 -30 0 4 1 4 1 2 4 8 + 58 80 0 0 4 1 4 1 2 4 8 + 59 80 30 0 4 1 4 1 2 4 8 + 60 110 -30 0 4 1 4 1 2 4 8 + 61 110 30 0 4 1 4 1 2 4 8 + 62 140 -30 0 4 1 4 1 2 4 8 + 63 140 0 0 4 1 4 1 2 4 8 + 64 140 30 0 4 1 4 1 2 4 8 + 65 70 -40 0 2 1 4 1 2 4 8 + 66 70 0 0 2 1 4 1 2 4 8 + 67 70 40 0 2 1 4 1 2 4 8 + 68 110 -40 0 2 1 4 1 2 4 8 + 69 110 40 0 2 1 4 1 2 4 8 + 70 150 -40 0 2 1 4 1 2 4 8 + 71 150 0 0 2 1 4 1 2 4 8 + 72 150 40 0 2 1 4 1 2 4 8 + 73 60 -50 0 1 1 4 1 2 4 8 + 74 60 0 0 1 1 4 1 2 4 8 + 75 60 50 0 1 1 4 1 2 4 8 + 76 110 -50 0 1 1 4 1 2 4 8 + 77 110 50 0 1 1 4 1 2 4 8 + 78 160 -50 0 1 1 4 1 2 4 8 + 79 160 0 0 1 1 4 1 2 4 8 + 80 160 50 0 1 1 4 1 2 4 8 + 81 100 100 0 12 1 4 1 2 4 8 + 82 100 110 0 12 1 4 1 2 4 8 + 83 100 120 0 12 1 4 1 2 4 8 + 84 110 100 0 12 1 4 1 2 4 8 + 85 110 120 0 12 1 4 1 2 4 8 + 86 120 100 0 12 1 4 1 2 4 8 + 87 120 110 0 12 1 4 1 2 4 8 + 88 120 120 0 12 1 4 1 2 4 8 + 89 90 90 0 8 1 4 1 2 4 8 + 90 90 110 0 8 1 4 1 2 4 8 + 91 90 130 0 8 1 4 1 2 4 8 + 92 110 90 0 8 1 4 1 2 4 8 + 93 110 130 0 8 1 4 1 2 4 8 + 94 130 90 0 8 1 4 1 2 4 8 + 95 130 110 0 8 1 4 1 2 4 8 + 96 130 130 0 8 1 4 1 2 4 8 + 97 80 80 0 4 1 4 1 2 4 8 + 98 80 110 0 4 1 4 1 2 4 8 + 99 80 140 0 4 1 4 1 2 4 8 +100 110 80 0 4 1 4 1 2 4 8 +101 110 140 0 4 1 4 1 2 4 8 +102 140 80 0 4 1 4 1 2 4 8 +103 140 110 0 4 1 4 1 2 4 8 +104 140 140 0 4 1 4 1 2 4 8 +105 70 70 0 2 1 4 1 2 4 8 +106 70 110 0 2 1 4 1 2 4 8 +107 70 150 0 2 1 4 1 2 4 8 +108 110 70 0 2 1 4 1 2 4 8 +109 110 150 0 2 1 4 1 2 4 8 +110 150 70 0 2 1 4 1 2 4 8 +111 150 110 0 2 1 4 1 2 4 8 +112 150 150 0 2 1 4 1 2 4 8 +113 60 60 0 1 1 4 1 2 4 8 +114 60 110 0 1 1 4 1 2 4 8 +115 60 160 0 1 1 4 1 2 4 8 +116 110 60 0 1 1 4 1 2 4 8 +117 110 160 0 1 1 4 1 2 4 8 +118 160 60 0 1 1 4 1 2 4 8 +119 160 110 0 1 1 4 1 2 4 8 +120 160 160 0 1 1 4 1 2 4 8 +121 -10 100 0 12 1 4 1 2 4 8 +122 -10 110 0 12 1 4 1 2 4 8 +123 -10 120 0 12 1 4 1 2 4 8 +124 0 100 0 12 1 4 1 2 4 8 +125 0 120 0 12 1 4 1 2 4 8 +126 10 100 0 12 1 4 1 2 4 8 +127 10 110 0 12 1 4 1 2 4 8 +128 10 120 0 12 1 4 1 2 4 8 +129 -20 90 0 8 1 4 1 2 4 8 +130 -20 110 0 8 1 4 1 2 4 8 +131 -20 130 0 8 1 4 1 2 4 8 +132 0 90 0 8 1 4 1 2 4 8 +133 0 130 0 8 1 4 1 2 4 8 +134 20 90 0 8 1 4 1 2 4 8 +135 20 110 0 8 1 4 1 2 4 8 +136 20 130 0 8 1 4 1 2 4 8 +137 -30 80 0 4 1 4 1 2 4 8 +138 -30 110 0 4 1 4 1 2 4 8 +139 -30 140 0 4 1 4 1 2 4 8 +140 0 80 0 4 1 4 1 2 4 8 +141 0 140 0 4 1 4 1 2 4 8 +142 30 80 0 4 1 4 1 2 4 8 +143 30 110 0 4 1 4 1 2 4 8 +144 30 140 0 4 1 4 1 2 4 8 +145 -40 70 0 2 1 4 1 2 4 8 +146 -40 110 0 2 1 4 1 2 4 8 +147 -40 150 0 2 1 4 1 2 4 8 +148 0 70 0 2 1 4 1 2 4 8 +149 0 150 0 2 1 4 1 2 4 8 +150 40 70 0 2 1 4 1 2 4 8 +151 40 110 0 2 1 4 1 2 4 8 +152 40 150 0 2 1 4 1 2 4 8 +153 -50 60 0 1 1 4 1 2 4 8 +154 -50 110 0 1 1 4 1 2 4 8 +155 -50 160 0 1 1 4 1 2 4 8 +156 0 60 0 1 1 4 1 2 4 8 +157 0 160 0 1 1 4 1 2 4 8 +158 50 60 0 1 1 4 1 2 4 8 +159 50 110 0 1 1 4 1 2 4 8 +160 50 160 0 1 1 4 1 2 4 8 +161 0 0 0 0 0 0 +162 110 0 0 0 0 0 +163 110 110 0 0 0 0 +164 0 110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p16.res b/jsprit-instances/instances/cordeau/p16.res new file mode 100644 index 00000000..bb640208 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p16.res @@ -0,0 +1,17 @@ +2572.23 +1 1 196.08 58 0 5 13 21 29 37 156 145 153 35 27 19 11 3 0 +1 2 170.71 54 0 1 9 17 25 33 34 26 18 10 2 0 +1 3 128.48 51 0 6 14 22 36 28 20 12 4 0 +1 4 96.57 46 0 8 16 31 23 15 7 0 +2 1 198.99 60 0 43 51 59 67 75 113 105 97 69 61 53 45 0 +2 2 196.08 58 0 41 49 57 65 73 38 30 39 74 66 58 50 42 0 +2 3 128.48 51 0 47 55 63 71 79 64 56 48 0 +2 4 170.71 54 0 46 54 62 70 78 76 68 60 52 44 0 +3 1 196.08 58 0 86 94 102 110 118 80 72 77 116 108 100 92 84 0 +3 2 170.71 54 0 88 96 104 112 120 119 111 103 95 87 0 +3 3 96.57 46 0 81 89 106 98 90 82 0 +3 4 128.48 51 0 83 91 99 117 109 101 93 85 0 +4 1 198.99 60 0 126 134 142 150 158 40 32 24 148 140 132 124 0 +4 2 128.48 51 0 122 130 138 146 154 137 129 121 0 +4 3 170.71 54 0 125 133 141 149 157 155 147 139 131 123 0 +4 4 196.08 58 0 127 135 143 151 159 114 107 115 160 152 144 136 128 0 diff --git a/jsprit-instances/instances/cordeau/p17 b/jsprit-instances/instances/cordeau/p17 new file mode 100644 index 00000000..3607c1e5 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p17 @@ -0,0 +1,169 @@ +2 5 160 4 +180 60 +180 60 +180 60 +180 60 + 1 -10 -10 0 12 1 4 1 2 4 8 + 2 -10 0 0 12 1 4 1 2 4 8 + 3 -10 10 0 12 1 4 1 2 4 8 + 4 0 -10 0 12 1 4 1 2 4 8 + 5 0 10 0 12 1 4 1 2 4 8 + 6 10 -10 0 12 1 4 1 2 4 8 + 7 10 0 0 12 1 4 1 2 4 8 + 8 10 10 0 12 1 4 1 2 4 8 + 9 -20 -20 0 8 1 4 1 2 4 8 + 10 -20 0 0 8 1 4 1 2 4 8 + 11 -20 20 0 8 1 4 1 2 4 8 + 12 0 -20 0 8 1 4 1 2 4 8 + 13 0 20 0 8 1 4 1 2 4 8 + 14 20 -20 0 8 1 4 1 2 4 8 + 15 20 0 0 8 1 4 1 2 4 8 + 16 20 20 0 8 1 4 1 2 4 8 + 17 -30 -30 0 4 1 4 1 2 4 8 + 18 -30 0 0 4 1 4 1 2 4 8 + 19 -30 30 0 4 1 4 1 2 4 8 + 20 0 -30 0 4 1 4 1 2 4 8 + 21 0 30 0 4 1 4 1 2 4 8 + 22 30 -30 0 4 1 4 1 2 4 8 + 23 30 0 0 4 1 4 1 2 4 8 + 24 30 30 0 4 1 4 1 2 4 8 + 25 -40 -40 0 2 1 4 1 2 4 8 + 26 -40 0 0 2 1 4 1 2 4 8 + 27 -40 40 0 2 1 4 1 2 4 8 + 28 0 -40 0 2 1 4 1 2 4 8 + 29 0 40 0 2 1 4 1 2 4 8 + 30 40 -40 0 2 1 4 1 2 4 8 + 31 40 0 0 2 1 4 1 2 4 8 + 32 40 40 0 2 1 4 1 2 4 8 + 33 -50 -50 0 1 1 4 1 2 4 8 + 34 -50 0 0 1 1 4 1 2 4 8 + 35 -50 50 0 1 1 4 1 2 4 8 + 36 0 -50 0 1 1 4 1 2 4 8 + 37 0 50 0 1 1 4 1 2 4 8 + 38 50 -50 0 1 1 4 1 2 4 8 + 39 50 0 0 1 1 4 1 2 4 8 + 40 50 50 0 1 1 4 1 2 4 8 + 41 100 -10 0 12 1 4 1 2 4 8 + 42 100 0 0 12 1 4 1 2 4 8 + 43 100 10 0 12 1 4 1 2 4 8 + 44 110 -10 0 12 1 4 1 2 4 8 + 45 110 10 0 12 1 4 1 2 4 8 + 46 120 -10 0 12 1 4 1 2 4 8 + 47 120 0 0 12 1 4 1 2 4 8 + 48 120 10 0 12 1 4 1 2 4 8 + 49 90 -20 0 8 1 4 1 2 4 8 + 50 90 0 0 8 1 4 1 2 4 8 + 51 90 20 0 8 1 4 1 2 4 8 + 52 110 -20 0 8 1 4 1 2 4 8 + 53 110 20 0 8 1 4 1 2 4 8 + 54 130 -20 0 8 1 4 1 2 4 8 + 55 130 0 0 8 1 4 1 2 4 8 + 56 130 20 0 8 1 4 1 2 4 8 + 57 80 -30 0 4 1 4 1 2 4 8 + 58 80 0 0 4 1 4 1 2 4 8 + 59 80 30 0 4 1 4 1 2 4 8 + 60 110 -30 0 4 1 4 1 2 4 8 + 61 110 30 0 4 1 4 1 2 4 8 + 62 140 -30 0 4 1 4 1 2 4 8 + 63 140 0 0 4 1 4 1 2 4 8 + 64 140 30 0 4 1 4 1 2 4 8 + 65 70 -40 0 2 1 4 1 2 4 8 + 66 70 0 0 2 1 4 1 2 4 8 + 67 70 40 0 2 1 4 1 2 4 8 + 68 110 -40 0 2 1 4 1 2 4 8 + 69 110 40 0 2 1 4 1 2 4 8 + 70 150 -40 0 2 1 4 1 2 4 8 + 71 150 0 0 2 1 4 1 2 4 8 + 72 150 40 0 2 1 4 1 2 4 8 + 73 60 -50 0 1 1 4 1 2 4 8 + 74 60 0 0 1 1 4 1 2 4 8 + 75 60 50 0 1 1 4 1 2 4 8 + 76 110 -50 0 1 1 4 1 2 4 8 + 77 110 50 0 1 1 4 1 2 4 8 + 78 160 -50 0 1 1 4 1 2 4 8 + 79 160 0 0 1 1 4 1 2 4 8 + 80 160 50 0 1 1 4 1 2 4 8 + 81 100 100 0 12 1 4 1 2 4 8 + 82 100 110 0 12 1 4 1 2 4 8 + 83 100 120 0 12 1 4 1 2 4 8 + 84 110 100 0 12 1 4 1 2 4 8 + 85 110 120 0 12 1 4 1 2 4 8 + 86 120 100 0 12 1 4 1 2 4 8 + 87 120 110 0 12 1 4 1 2 4 8 + 88 120 120 0 12 1 4 1 2 4 8 + 89 90 90 0 8 1 4 1 2 4 8 + 90 90 110 0 8 1 4 1 2 4 8 + 91 90 130 0 8 1 4 1 2 4 8 + 92 110 90 0 8 1 4 1 2 4 8 + 93 110 130 0 8 1 4 1 2 4 8 + 94 130 90 0 8 1 4 1 2 4 8 + 95 130 110 0 8 1 4 1 2 4 8 + 96 130 130 0 8 1 4 1 2 4 8 + 97 80 80 0 4 1 4 1 2 4 8 + 98 80 110 0 4 1 4 1 2 4 8 + 99 80 140 0 4 1 4 1 2 4 8 +100 110 80 0 4 1 4 1 2 4 8 +101 110 140 0 4 1 4 1 2 4 8 +102 140 80 0 4 1 4 1 2 4 8 +103 140 110 0 4 1 4 1 2 4 8 +104 140 140 0 4 1 4 1 2 4 8 +105 70 70 0 2 1 4 1 2 4 8 +106 70 110 0 2 1 4 1 2 4 8 +107 70 150 0 2 1 4 1 2 4 8 +108 110 70 0 2 1 4 1 2 4 8 +109 110 150 0 2 1 4 1 2 4 8 +110 150 70 0 2 1 4 1 2 4 8 +111 150 110 0 2 1 4 1 2 4 8 +112 150 150 0 2 1 4 1 2 4 8 +113 60 60 0 1 1 4 1 2 4 8 +114 60 110 0 1 1 4 1 2 4 8 +115 60 160 0 1 1 4 1 2 4 8 +116 110 60 0 1 1 4 1 2 4 8 +117 110 160 0 1 1 4 1 2 4 8 +118 160 60 0 1 1 4 1 2 4 8 +119 160 110 0 1 1 4 1 2 4 8 +120 160 160 0 1 1 4 1 2 4 8 +121 -10 100 0 12 1 4 1 2 4 8 +122 -10 110 0 12 1 4 1 2 4 8 +123 -10 120 0 12 1 4 1 2 4 8 +124 0 100 0 12 1 4 1 2 4 8 +125 0 120 0 12 1 4 1 2 4 8 +126 10 100 0 12 1 4 1 2 4 8 +127 10 110 0 12 1 4 1 2 4 8 +128 10 120 0 12 1 4 1 2 4 8 +129 -20 90 0 8 1 4 1 2 4 8 +130 -20 110 0 8 1 4 1 2 4 8 +131 -20 130 0 8 1 4 1 2 4 8 +132 0 90 0 8 1 4 1 2 4 8 +133 0 130 0 8 1 4 1 2 4 8 +134 20 90 0 8 1 4 1 2 4 8 +135 20 110 0 8 1 4 1 2 4 8 +136 20 130 0 8 1 4 1 2 4 8 +137 -30 80 0 4 1 4 1 2 4 8 +138 -30 110 0 4 1 4 1 2 4 8 +139 -30 140 0 4 1 4 1 2 4 8 +140 0 80 0 4 1 4 1 2 4 8 +141 0 140 0 4 1 4 1 2 4 8 +142 30 80 0 4 1 4 1 2 4 8 +143 30 110 0 4 1 4 1 2 4 8 +144 30 140 0 4 1 4 1 2 4 8 +145 -40 70 0 2 1 4 1 2 4 8 +146 -40 110 0 2 1 4 1 2 4 8 +147 -40 150 0 2 1 4 1 2 4 8 +148 0 70 0 2 1 4 1 2 4 8 +149 0 150 0 2 1 4 1 2 4 8 +150 40 70 0 2 1 4 1 2 4 8 +151 40 110 0 2 1 4 1 2 4 8 +152 40 150 0 2 1 4 1 2 4 8 +153 -50 60 0 1 1 4 1 2 4 8 +154 -50 110 0 1 1 4 1 2 4 8 +155 -50 160 0 1 1 4 1 2 4 8 +156 0 60 0 1 1 4 1 2 4 8 +157 0 160 0 1 1 4 1 2 4 8 +158 50 60 0 1 1 4 1 2 4 8 +159 50 110 0 1 1 4 1 2 4 8 +160 50 160 0 1 1 4 1 2 4 8 +161 0 0 0 0 0 0 +162 110 0 0 0 0 0 +163 110 110 0 0 0 0 +164 0 110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p17.res b/jsprit-instances/instances/cordeau/p17.res new file mode 100644 index 00000000..8a4f780c --- /dev/null +++ b/jsprit-instances/instances/cordeau/p17.res @@ -0,0 +1,17 @@ +2709.09 +1 1 170.71 54 0 1 9 17 25 33 36 28 20 12 4 0 +1 2 174.56 54 0 7 15 23 31 73 38 30 22 14 6 0 +1 3 170.71 54 0 2 10 18 26 34 35 27 19 11 3 0 +1 4 161.29 54 0 5 13 21 29 37 156 32 24 16 8 0 +2 1 170.71 54 0 47 55 63 71 79 80 72 64 56 48 0 +2 2 170.71 54 0 46 54 62 70 78 76 68 60 52 44 0 +2 3 161.29 54 0 42 50 58 66 74 39 65 57 49 41 0 +2 4 161.29 54 0 45 53 61 69 77 116 67 59 51 43 0 +3 1 170.71 54 0 86 94 102 110 118 119 111 103 95 87 0 +3 2 161.29 54 0 82 90 98 106 114 159 107 99 91 83 0 +3 3 174.56 54 0 84 92 100 108 75 113 105 97 89 81 0 +3 4 170.71 54 0 85 93 101 109 117 120 112 104 96 88 0 +4 1 174.56 54 0 128 136 144 152 160 115 151 143 135 127 0 +4 2 174.56 54 0 126 134 142 150 158 40 148 140 132 124 0 +4 3 170.71 54 0 121 129 137 145 153 154 146 138 130 122 0 +4 4 170.71 54 0 125 133 141 149 157 155 147 139 131 123 0 diff --git a/jsprit-instances/instances/cordeau/p18 b/jsprit-instances/instances/cordeau/p18 new file mode 100644 index 00000000..7fbf4a24 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p18 @@ -0,0 +1,253 @@ +2 5 240 6 +0 60 +0 60 +0 60 +0 60 +0 60 +0 60 + 1 -10 -10 0 12 1 6 1 2 4 8 16 32 + 2 -10 0 0 12 1 6 1 2 4 8 16 32 + 3 -10 10 0 12 1 6 1 2 4 8 16 32 + 4 0 -10 0 12 1 6 1 2 4 8 16 32 + 5 0 10 0 12 1 6 1 2 4 8 16 32 + 6 10 -10 0 12 1 6 1 2 4 8 16 32 + 7 10 0 0 12 1 6 1 2 4 8 16 32 + 8 10 10 0 12 1 6 1 2 4 8 16 32 + 9 -20 -20 0 8 1 6 1 2 4 8 16 32 + 10 -20 0 0 8 1 6 1 2 4 8 16 32 + 11 -20 20 0 8 1 6 1 2 4 8 16 32 + 12 0 -20 0 8 1 6 1 2 4 8 16 32 + 13 0 20 0 8 1 6 1 2 4 8 16 32 + 14 20 -20 0 8 1 6 1 2 4 8 16 32 + 15 20 0 0 8 1 6 1 2 4 8 16 32 + 16 20 20 0 8 1 6 1 2 4 8 16 32 + 17 -30 -30 0 4 1 6 1 2 4 8 16 32 + 18 -30 0 0 4 1 6 1 2 4 8 16 32 + 19 -30 30 0 4 1 6 1 2 4 8 16 32 + 20 0 -30 0 4 1 6 1 2 4 8 16 32 + 21 0 30 0 4 1 6 1 2 4 8 16 32 + 22 30 -30 0 4 1 6 1 2 4 8 16 32 + 23 30 0 0 4 1 6 1 2 4 8 16 32 + 24 30 30 0 4 1 6 1 2 4 8 16 32 + 25 -40 -40 0 2 1 6 1 2 4 8 16 32 + 26 -40 0 0 2 1 6 1 2 4 8 16 32 + 27 -40 40 0 2 1 6 1 2 4 8 16 32 + 28 0 -40 0 2 1 6 1 2 4 8 16 32 + 29 0 40 0 2 1 6 1 2 4 8 16 32 + 30 40 -40 0 2 1 6 1 2 4 8 16 32 + 31 40 0 0 2 1 6 1 2 4 8 16 32 + 32 40 40 0 2 1 6 1 2 4 8 16 32 + 33 -50 -50 0 1 1 6 1 2 4 8 16 32 + 34 -50 0 0 1 1 6 1 2 4 8 16 32 + 35 -50 50 0 1 1 6 1 2 4 8 16 32 + 36 0 -50 0 1 1 6 1 2 4 8 16 32 + 37 0 50 0 1 1 6 1 2 4 8 16 32 + 38 50 -50 0 1 1 6 1 2 4 8 16 32 + 39 50 0 0 1 1 6 1 2 4 8 16 32 + 40 50 50 0 1 1 6 1 2 4 8 16 32 + 41 100 -10 0 12 1 6 1 2 4 8 16 32 + 42 100 0 0 12 1 6 1 2 4 8 16 32 + 43 100 10 0 12 1 6 1 2 4 8 16 32 + 44 110 -10 0 12 1 6 1 2 4 8 16 32 + 45 110 10 0 12 1 6 1 2 4 8 16 32 + 46 120 -10 0 12 1 6 1 2 4 8 16 32 + 47 120 0 0 12 1 6 1 2 4 8 16 32 + 48 120 10 0 12 1 6 1 2 4 8 16 32 + 49 90 -20 0 8 1 6 1 2 4 8 16 32 + 50 90 0 0 8 1 6 1 2 4 8 16 32 + 51 90 20 0 8 1 6 1 2 4 8 16 32 + 52 110 -20 0 8 1 6 1 2 4 8 16 32 + 53 110 20 0 8 1 6 1 2 4 8 16 32 + 54 130 -20 0 8 1 6 1 2 4 8 16 32 + 55 130 0 0 8 1 6 1 2 4 8 16 32 + 56 130 20 0 8 1 6 1 2 4 8 16 32 + 57 80 -30 0 4 1 6 1 2 4 8 16 32 + 58 80 0 0 4 1 6 1 2 4 8 16 32 + 59 80 30 0 4 1 6 1 2 4 8 16 32 + 60 110 -30 0 4 1 6 1 2 4 8 16 32 + 61 110 30 0 4 1 6 1 2 4 8 16 32 + 62 140 -30 0 4 1 6 1 2 4 8 16 32 + 63 140 0 0 4 1 6 1 2 4 8 16 32 + 64 140 30 0 4 1 6 1 2 4 8 16 32 + 65 70 -40 0 2 1 6 1 2 4 8 16 32 + 66 70 0 0 2 1 6 1 2 4 8 16 32 + 67 70 40 0 2 1 6 1 2 4 8 16 32 + 68 110 -40 0 2 1 6 1 2 4 8 16 32 + 69 110 40 0 2 1 6 1 2 4 8 16 32 + 70 150 -40 0 2 1 6 1 2 4 8 16 32 + 71 150 0 0 2 1 6 1 2 4 8 16 32 + 72 150 40 0 2 1 6 1 2 4 8 16 32 + 73 60 -50 0 1 1 6 1 2 4 8 16 32 + 74 60 0 0 1 1 6 1 2 4 8 16 32 + 75 60 50 0 1 1 6 1 2 4 8 16 32 + 76 110 -50 0 1 1 6 1 2 4 8 16 32 + 77 110 50 0 1 1 6 1 2 4 8 16 32 + 78 160 -50 0 1 1 6 1 2 4 8 16 32 + 79 160 0 0 1 1 6 1 2 4 8 16 32 + 80 160 50 0 1 1 6 1 2 4 8 16 32 + 81 100 100 0 12 1 6 1 2 4 8 16 32 + 82 100 110 0 12 1 6 1 2 4 8 16 32 + 83 100 120 0 12 1 6 1 2 4 8 16 32 + 84 110 100 0 12 1 6 1 2 4 8 16 32 + 85 110 120 0 12 1 6 1 2 4 8 16 32 + 86 120 100 0 12 1 6 1 2 4 8 16 32 + 87 120 110 0 12 1 6 1 2 4 8 16 32 + 88 120 120 0 12 1 6 1 2 4 8 16 32 + 89 90 90 0 8 1 6 1 2 4 8 16 32 + 90 90 110 0 8 1 6 1 2 4 8 16 32 + 91 90 130 0 8 1 6 1 2 4 8 16 32 + 92 110 90 0 8 1 6 1 2 4 8 16 32 + 93 110 130 0 8 1 6 1 2 4 8 16 32 + 94 130 90 0 8 1 6 1 2 4 8 16 32 + 95 130 110 0 8 1 6 1 2 4 8 16 32 + 96 130 130 0 8 1 6 1 2 4 8 16 32 + 97 80 80 0 4 1 6 1 2 4 8 16 32 + 98 80 110 0 4 1 6 1 2 4 8 16 32 + 99 80 140 0 4 1 6 1 2 4 8 16 32 +100 110 80 0 4 1 6 1 2 4 8 16 32 +101 110 140 0 4 1 6 1 2 4 8 16 32 +102 140 80 0 4 1 6 1 2 4 8 16 32 +103 140 110 0 4 1 6 1 2 4 8 16 32 +104 140 140 0 4 1 6 1 2 4 8 16 32 +105 70 70 0 2 1 6 1 2 4 8 16 32 +106 70 110 0 2 1 6 1 2 4 8 16 32 +107 70 150 0 2 1 6 1 2 4 8 16 32 +108 110 70 0 2 1 6 1 2 4 8 16 32 +109 110 150 0 2 1 6 1 2 4 8 16 32 +110 150 70 0 2 1 6 1 2 4 8 16 32 +111 150 110 0 2 1 6 1 2 4 8 16 32 +112 150 150 0 2 1 6 1 2 4 8 16 32 +113 60 60 0 1 1 6 1 2 4 8 16 32 +114 60 110 0 1 1 6 1 2 4 8 16 32 +115 60 160 0 1 1 6 1 2 4 8 16 32 +116 110 60 0 1 1 6 1 2 4 8 16 32 +117 110 160 0 1 1 6 1 2 4 8 16 32 +118 160 60 0 1 1 6 1 2 4 8 16 32 +119 160 110 0 1 1 6 1 2 4 8 16 32 +120 160 160 0 1 1 6 1 2 4 8 16 32 +121 -10 100 0 12 1 6 1 2 4 8 16 32 +122 -10 110 0 12 1 6 1 2 4 8 16 32 +123 -10 120 0 12 1 6 1 2 4 8 16 32 +124 0 100 0 12 1 6 1 2 4 8 16 32 +125 0 120 0 12 1 6 1 2 4 8 16 32 +126 10 100 0 12 1 6 1 2 4 8 16 32 +127 10 110 0 12 1 6 1 2 4 8 16 32 +128 10 120 0 12 1 6 1 2 4 8 16 32 +129 -20 90 0 8 1 6 1 2 4 8 16 32 +130 -20 110 0 8 1 6 1 2 4 8 16 32 +131 -20 130 0 8 1 6 1 2 4 8 16 32 +132 0 90 0 8 1 6 1 2 4 8 16 32 +133 0 130 0 8 1 6 1 2 4 8 16 32 +134 20 90 0 8 1 6 1 2 4 8 16 32 +135 20 110 0 8 1 6 1 2 4 8 16 32 +136 20 130 0 8 1 6 1 2 4 8 16 32 +137 -30 80 0 4 1 6 1 2 4 8 16 32 +138 -30 110 0 4 1 6 1 2 4 8 16 32 +139 -30 140 0 4 1 6 1 2 4 8 16 32 +140 0 80 0 4 1 6 1 2 4 8 16 32 +141 0 140 0 4 1 6 1 2 4 8 16 32 +142 30 80 0 4 1 6 1 2 4 8 16 32 +143 30 110 0 4 1 6 1 2 4 8 16 32 +144 30 140 0 4 1 6 1 2 4 8 16 32 +145 -40 70 0 2 1 6 1 2 4 8 16 32 +146 -40 110 0 2 1 6 1 2 4 8 16 32 +147 -40 150 0 2 1 6 1 2 4 8 16 32 +148 0 70 0 2 1 6 1 2 4 8 16 32 +149 0 150 0 2 1 6 1 2 4 8 16 32 +150 40 70 0 2 1 6 1 2 4 8 16 32 +151 40 110 0 2 1 6 1 2 4 8 16 32 +152 40 150 0 2 1 6 1 2 4 8 16 32 +153 -50 60 0 1 1 6 1 2 4 8 16 32 +154 -50 110 0 1 1 6 1 2 4 8 16 32 +155 -50 160 0 1 1 6 1 2 4 8 16 32 +156 0 60 0 1 1 6 1 2 4 8 16 32 +157 0 160 0 1 1 6 1 2 4 8 16 32 +158 50 60 0 1 1 6 1 2 4 8 16 32 +159 50 110 0 1 1 6 1 2 4 8 16 32 +160 50 160 0 1 1 6 1 2 4 8 16 32 +161 -120 100 0 12 1 6 1 2 4 8 16 32 +162 -120 110 0 12 1 6 1 2 4 8 16 32 +163 -120 120 0 12 1 6 1 2 4 8 16 32 +164 -110 100 0 12 1 6 1 2 4 8 16 32 +165 -110 120 0 12 1 6 1 2 4 8 16 32 +166 -100 100 0 12 1 6 1 2 4 8 16 32 +167 -100 110 0 12 1 6 1 2 4 8 16 32 +168 -100 120 0 12 1 6 1 2 4 8 16 32 +169 -130 90 0 8 1 6 1 2 4 8 16 32 +170 -130 110 0 8 1 6 1 2 4 8 16 32 +171 -130 130 0 8 1 6 1 2 4 8 16 32 +172 -110 90 0 8 1 6 1 2 4 8 16 32 +173 -110 130 0 8 1 6 1 2 4 8 16 32 +174 -90 90 0 8 1 6 1 2 4 8 16 32 +175 -90 110 0 8 1 6 1 2 4 8 16 32 +176 -90 130 0 8 1 6 1 2 4 8 16 32 +177 -140 80 0 4 1 6 1 2 4 8 16 32 +178 -140 110 0 4 1 6 1 2 4 8 16 32 +179 -140 140 0 4 1 6 1 2 4 8 16 32 +180 -110 80 0 4 1 6 1 2 4 8 16 32 +181 -110 140 0 4 1 6 1 2 4 8 16 32 +182 -80 80 0 4 1 6 1 2 4 8 16 32 +183 -80 110 0 4 1 6 1 2 4 8 16 32 +184 -80 140 0 4 1 6 1 2 4 8 16 32 +185 -150 70 0 2 1 6 1 2 4 8 16 32 +186 -150 110 0 2 1 6 1 2 4 8 16 32 +187 -150 150 0 2 1 6 1 2 4 8 16 32 +188 -110 70 0 2 1 6 1 2 4 8 16 32 +189 -110 150 0 2 1 6 1 2 4 8 16 32 +190 -70 70 0 2 1 6 1 2 4 8 16 32 +191 -70 110 0 2 1 6 1 2 4 8 16 32 +192 -70 150 0 2 1 6 1 2 4 8 16 32 +193 -160 60 0 1 1 6 1 2 4 8 16 32 +194 -160 110 0 1 1 6 1 2 4 8 16 32 +195 -160 160 0 1 1 6 1 2 4 8 16 32 +196 -110 60 0 1 1 6 1 2 4 8 16 32 +197 -110 160 0 1 1 6 1 2 4 8 16 32 +198 -60 60 0 1 1 6 1 2 4 8 16 32 +199 -60 110 0 1 1 6 1 2 4 8 16 32 +200 -60 160 0 1 1 6 1 2 4 8 16 32 +201 -120 -10 0 12 1 6 1 2 4 8 16 32 +202 -120 0 0 12 1 6 1 2 4 8 16 32 +203 -120 10 0 12 1 6 1 2 4 8 16 32 +204 -110 -10 0 12 1 6 1 2 4 8 16 32 +205 -110 10 0 12 1 6 1 2 4 8 16 32 +206 -100 -10 0 12 1 6 1 2 4 8 16 32 +207 -100 0 0 12 1 6 1 2 4 8 16 32 +208 -100 10 0 12 1 6 1 2 4 8 16 32 +209 -130 -20 0 8 1 6 1 2 4 8 16 32 +210 -130 0 0 8 1 6 1 2 4 8 16 32 +211 -130 20 0 8 1 6 1 2 4 8 16 32 +212 -110 -20 0 8 1 6 1 2 4 8 16 32 +213 -110 20 0 8 1 6 1 2 4 8 16 32 +214 -90 -20 0 8 1 6 1 2 4 8 16 32 +215 -90 0 0 8 1 6 1 2 4 8 16 32 +216 -90 20 0 8 1 6 1 2 4 8 16 32 +217 -140 -30 0 4 1 6 1 2 4 8 16 32 +218 -140 0 0 4 1 6 1 2 4 8 16 32 +219 -140 30 0 4 1 6 1 2 4 8 16 32 +220 -110 -30 0 4 1 6 1 2 4 8 16 32 +221 -110 30 0 4 1 6 1 2 4 8 16 32 +222 -80 -30 0 4 1 6 1 2 4 8 16 32 +223 -80 0 0 4 1 6 1 2 4 8 16 32 +224 -80 30 0 4 1 6 1 2 4 8 16 32 +225 -150 -40 0 2 1 6 1 2 4 8 16 32 +226 -150 0 0 2 1 6 1 2 4 8 16 32 +227 -150 40 0 2 1 6 1 2 4 8 16 32 +228 -110 -40 0 2 1 6 1 2 4 8 16 32 +229 -110 40 0 2 1 6 1 2 4 8 16 32 +230 -70 -40 0 2 1 6 1 2 4 8 16 32 +231 -70 0 0 2 1 6 1 2 4 8 16 32 +232 -70 40 0 2 1 6 1 2 4 8 16 32 +233 -160 -50 0 1 1 6 1 2 4 8 16 32 +234 -160 0 0 1 1 6 1 2 4 8 16 32 +235 -160 50 0 1 1 6 1 2 4 8 16 32 +236 -110 -50 0 1 1 6 1 2 4 8 16 32 +237 -110 50 0 1 1 6 1 2 4 8 16 32 +238 -60 -50 0 1 1 6 1 2 4 8 16 32 +239 -60 0 0 1 1 6 1 2 4 8 16 32 +240 -60 50 0 1 1 6 1 2 4 8 16 32 +241 0 0 0 0 0 0 +242 110 0 0 0 0 0 +243 110 110 0 0 0 0 +244 0 110 0 0 0 0 +245 -110 110 0 0 0 0 +246 -110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p18.res b/jsprit-instances/instances/cordeau/p18.res new file mode 100644 index 00000000..60aee390 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p18.res @@ -0,0 +1,25 @@ +3702.85 +1 1 188.93 55 0 6 14 22 30 73 38 36 28 20 12 4 0 +1 2 60.00 60 0 2 3 5 8 7 0 +1 3 221.42 60 0 10 18 26 34 239 231 214 222 230 238 33 25 17 9 1 0 +2 1 233.14 60 0 56 64 72 80 118 110 102 94 92 100 108 116 77 69 61 53 0 +2 2 147.80 53 0 41 49 57 65 76 68 60 52 44 0 +2 3 54.14 48 0 42 43 45 48 0 +2 4 170.71 54 0 47 55 63 71 79 78 70 62 54 46 0 +2 5 233.14 60 0 50 58 66 74 39 31 23 15 16 24 32 40 75 67 59 51 0 +3 1 54.14 48 0 86 84 81 82 0 +3 2 170.71 54 0 88 96 104 112 120 119 111 103 95 87 0 +3 3 188.93 55 0 83 91 99 107 160 115 117 109 101 93 85 0 +4 1 233.14 60 0 135 143 151 159 114 106 98 90 89 97 105 113 158 150 142 134 0 +4 2 147.80 53 0 128 136 144 152 157 149 141 133 125 0 +4 3 60.00 60 0 127 126 124 121 122 0 +4 4 233.14 60 0 132 140 148 156 37 29 21 13 11 19 27 35 153 145 137 129 0 +4 5 221.42 60 0 130 138 146 154 199 191 176 184 192 200 155 147 139 131 123 0 + +5 1 86.50 60 0 167 168 175 183 166 164 0 +5 2 188.93 55 0 161 169 177 185 235 193 194 186 178 170 162 0 +5 3 170.71 54 0 163 171 179 187 195 197 189 181 173 165 0 +6 1 233.14 60 0 213 221 229 237 196 188 180 172 174 182 190 198 240 232 224 216 0 +6 2 170.71 54 0 201 209 217 225 233 236 228 220 212 204 0 +6 3 147.80 53 0 203 211 219 227 234 226 218 210 202 0 +6 4 86.50 60 0 207 206 223 215 208 205 0 diff --git a/jsprit-instances/instances/cordeau/p19 b/jsprit-instances/instances/cordeau/p19 new file mode 100644 index 00000000..90043806 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p19 @@ -0,0 +1,253 @@ +2 5 240 6 +200 60 +200 60 +200 60 +200 60 +200 60 +200 60 + 1 -10 -10 0 12 1 6 1 2 4 8 16 32 + 2 -10 0 0 12 1 6 1 2 4 8 16 32 + 3 -10 10 0 12 1 6 1 2 4 8 16 32 + 4 0 -10 0 12 1 6 1 2 4 8 16 32 + 5 0 10 0 12 1 6 1 2 4 8 16 32 + 6 10 -10 0 12 1 6 1 2 4 8 16 32 + 7 10 0 0 12 1 6 1 2 4 8 16 32 + 8 10 10 0 12 1 6 1 2 4 8 16 32 + 9 -20 -20 0 8 1 6 1 2 4 8 16 32 + 10 -20 0 0 8 1 6 1 2 4 8 16 32 + 11 -20 20 0 8 1 6 1 2 4 8 16 32 + 12 0 -20 0 8 1 6 1 2 4 8 16 32 + 13 0 20 0 8 1 6 1 2 4 8 16 32 + 14 20 -20 0 8 1 6 1 2 4 8 16 32 + 15 20 0 0 8 1 6 1 2 4 8 16 32 + 16 20 20 0 8 1 6 1 2 4 8 16 32 + 17 -30 -30 0 4 1 6 1 2 4 8 16 32 + 18 -30 0 0 4 1 6 1 2 4 8 16 32 + 19 -30 30 0 4 1 6 1 2 4 8 16 32 + 20 0 -30 0 4 1 6 1 2 4 8 16 32 + 21 0 30 0 4 1 6 1 2 4 8 16 32 + 22 30 -30 0 4 1 6 1 2 4 8 16 32 + 23 30 0 0 4 1 6 1 2 4 8 16 32 + 24 30 30 0 4 1 6 1 2 4 8 16 32 + 25 -40 -40 0 2 1 6 1 2 4 8 16 32 + 26 -40 0 0 2 1 6 1 2 4 8 16 32 + 27 -40 40 0 2 1 6 1 2 4 8 16 32 + 28 0 -40 0 2 1 6 1 2 4 8 16 32 + 29 0 40 0 2 1 6 1 2 4 8 16 32 + 30 40 -40 0 2 1 6 1 2 4 8 16 32 + 31 40 0 0 2 1 6 1 2 4 8 16 32 + 32 40 40 0 2 1 6 1 2 4 8 16 32 + 33 -50 -50 0 1 1 6 1 2 4 8 16 32 + 34 -50 0 0 1 1 6 1 2 4 8 16 32 + 35 -50 50 0 1 1 6 1 2 4 8 16 32 + 36 0 -50 0 1 1 6 1 2 4 8 16 32 + 37 0 50 0 1 1 6 1 2 4 8 16 32 + 38 50 -50 0 1 1 6 1 2 4 8 16 32 + 39 50 0 0 1 1 6 1 2 4 8 16 32 + 40 50 50 0 1 1 6 1 2 4 8 16 32 + 41 100 -10 0 12 1 6 1 2 4 8 16 32 + 42 100 0 0 12 1 6 1 2 4 8 16 32 + 43 100 10 0 12 1 6 1 2 4 8 16 32 + 44 110 -10 0 12 1 6 1 2 4 8 16 32 + 45 110 10 0 12 1 6 1 2 4 8 16 32 + 46 120 -10 0 12 1 6 1 2 4 8 16 32 + 47 120 0 0 12 1 6 1 2 4 8 16 32 + 48 120 10 0 12 1 6 1 2 4 8 16 32 + 49 90 -20 0 8 1 6 1 2 4 8 16 32 + 50 90 0 0 8 1 6 1 2 4 8 16 32 + 51 90 20 0 8 1 6 1 2 4 8 16 32 + 52 110 -20 0 8 1 6 1 2 4 8 16 32 + 53 110 20 0 8 1 6 1 2 4 8 16 32 + 54 130 -20 0 8 1 6 1 2 4 8 16 32 + 55 130 0 0 8 1 6 1 2 4 8 16 32 + 56 130 20 0 8 1 6 1 2 4 8 16 32 + 57 80 -30 0 4 1 6 1 2 4 8 16 32 + 58 80 0 0 4 1 6 1 2 4 8 16 32 + 59 80 30 0 4 1 6 1 2 4 8 16 32 + 60 110 -30 0 4 1 6 1 2 4 8 16 32 + 61 110 30 0 4 1 6 1 2 4 8 16 32 + 62 140 -30 0 4 1 6 1 2 4 8 16 32 + 63 140 0 0 4 1 6 1 2 4 8 16 32 + 64 140 30 0 4 1 6 1 2 4 8 16 32 + 65 70 -40 0 2 1 6 1 2 4 8 16 32 + 66 70 0 0 2 1 6 1 2 4 8 16 32 + 67 70 40 0 2 1 6 1 2 4 8 16 32 + 68 110 -40 0 2 1 6 1 2 4 8 16 32 + 69 110 40 0 2 1 6 1 2 4 8 16 32 + 70 150 -40 0 2 1 6 1 2 4 8 16 32 + 71 150 0 0 2 1 6 1 2 4 8 16 32 + 72 150 40 0 2 1 6 1 2 4 8 16 32 + 73 60 -50 0 1 1 6 1 2 4 8 16 32 + 74 60 0 0 1 1 6 1 2 4 8 16 32 + 75 60 50 0 1 1 6 1 2 4 8 16 32 + 76 110 -50 0 1 1 6 1 2 4 8 16 32 + 77 110 50 0 1 1 6 1 2 4 8 16 32 + 78 160 -50 0 1 1 6 1 2 4 8 16 32 + 79 160 0 0 1 1 6 1 2 4 8 16 32 + 80 160 50 0 1 1 6 1 2 4 8 16 32 + 81 100 100 0 12 1 6 1 2 4 8 16 32 + 82 100 110 0 12 1 6 1 2 4 8 16 32 + 83 100 120 0 12 1 6 1 2 4 8 16 32 + 84 110 100 0 12 1 6 1 2 4 8 16 32 + 85 110 120 0 12 1 6 1 2 4 8 16 32 + 86 120 100 0 12 1 6 1 2 4 8 16 32 + 87 120 110 0 12 1 6 1 2 4 8 16 32 + 88 120 120 0 12 1 6 1 2 4 8 16 32 + 89 90 90 0 8 1 6 1 2 4 8 16 32 + 90 90 110 0 8 1 6 1 2 4 8 16 32 + 91 90 130 0 8 1 6 1 2 4 8 16 32 + 92 110 90 0 8 1 6 1 2 4 8 16 32 + 93 110 130 0 8 1 6 1 2 4 8 16 32 + 94 130 90 0 8 1 6 1 2 4 8 16 32 + 95 130 110 0 8 1 6 1 2 4 8 16 32 + 96 130 130 0 8 1 6 1 2 4 8 16 32 + 97 80 80 0 4 1 6 1 2 4 8 16 32 + 98 80 110 0 4 1 6 1 2 4 8 16 32 + 99 80 140 0 4 1 6 1 2 4 8 16 32 +100 110 80 0 4 1 6 1 2 4 8 16 32 +101 110 140 0 4 1 6 1 2 4 8 16 32 +102 140 80 0 4 1 6 1 2 4 8 16 32 +103 140 110 0 4 1 6 1 2 4 8 16 32 +104 140 140 0 4 1 6 1 2 4 8 16 32 +105 70 70 0 2 1 6 1 2 4 8 16 32 +106 70 110 0 2 1 6 1 2 4 8 16 32 +107 70 150 0 2 1 6 1 2 4 8 16 32 +108 110 70 0 2 1 6 1 2 4 8 16 32 +109 110 150 0 2 1 6 1 2 4 8 16 32 +110 150 70 0 2 1 6 1 2 4 8 16 32 +111 150 110 0 2 1 6 1 2 4 8 16 32 +112 150 150 0 2 1 6 1 2 4 8 16 32 +113 60 60 0 1 1 6 1 2 4 8 16 32 +114 60 110 0 1 1 6 1 2 4 8 16 32 +115 60 160 0 1 1 6 1 2 4 8 16 32 +116 110 60 0 1 1 6 1 2 4 8 16 32 +117 110 160 0 1 1 6 1 2 4 8 16 32 +118 160 60 0 1 1 6 1 2 4 8 16 32 +119 160 110 0 1 1 6 1 2 4 8 16 32 +120 160 160 0 1 1 6 1 2 4 8 16 32 +121 -10 100 0 12 1 6 1 2 4 8 16 32 +122 -10 110 0 12 1 6 1 2 4 8 16 32 +123 -10 120 0 12 1 6 1 2 4 8 16 32 +124 0 100 0 12 1 6 1 2 4 8 16 32 +125 0 120 0 12 1 6 1 2 4 8 16 32 +126 10 100 0 12 1 6 1 2 4 8 16 32 +127 10 110 0 12 1 6 1 2 4 8 16 32 +128 10 120 0 12 1 6 1 2 4 8 16 32 +129 -20 90 0 8 1 6 1 2 4 8 16 32 +130 -20 110 0 8 1 6 1 2 4 8 16 32 +131 -20 130 0 8 1 6 1 2 4 8 16 32 +132 0 90 0 8 1 6 1 2 4 8 16 32 +133 0 130 0 8 1 6 1 2 4 8 16 32 +134 20 90 0 8 1 6 1 2 4 8 16 32 +135 20 110 0 8 1 6 1 2 4 8 16 32 +136 20 130 0 8 1 6 1 2 4 8 16 32 +137 -30 80 0 4 1 6 1 2 4 8 16 32 +138 -30 110 0 4 1 6 1 2 4 8 16 32 +139 -30 140 0 4 1 6 1 2 4 8 16 32 +140 0 80 0 4 1 6 1 2 4 8 16 32 +141 0 140 0 4 1 6 1 2 4 8 16 32 +142 30 80 0 4 1 6 1 2 4 8 16 32 +143 30 110 0 4 1 6 1 2 4 8 16 32 +144 30 140 0 4 1 6 1 2 4 8 16 32 +145 -40 70 0 2 1 6 1 2 4 8 16 32 +146 -40 110 0 2 1 6 1 2 4 8 16 32 +147 -40 150 0 2 1 6 1 2 4 8 16 32 +148 0 70 0 2 1 6 1 2 4 8 16 32 +149 0 150 0 2 1 6 1 2 4 8 16 32 +150 40 70 0 2 1 6 1 2 4 8 16 32 +151 40 110 0 2 1 6 1 2 4 8 16 32 +152 40 150 0 2 1 6 1 2 4 8 16 32 +153 -50 60 0 1 1 6 1 2 4 8 16 32 +154 -50 110 0 1 1 6 1 2 4 8 16 32 +155 -50 160 0 1 1 6 1 2 4 8 16 32 +156 0 60 0 1 1 6 1 2 4 8 16 32 +157 0 160 0 1 1 6 1 2 4 8 16 32 +158 50 60 0 1 1 6 1 2 4 8 16 32 +159 50 110 0 1 1 6 1 2 4 8 16 32 +160 50 160 0 1 1 6 1 2 4 8 16 32 +161 -120 100 0 12 1 6 1 2 4 8 16 32 +162 -120 110 0 12 1 6 1 2 4 8 16 32 +163 -120 120 0 12 1 6 1 2 4 8 16 32 +164 -110 100 0 12 1 6 1 2 4 8 16 32 +165 -110 120 0 12 1 6 1 2 4 8 16 32 +166 -100 100 0 12 1 6 1 2 4 8 16 32 +167 -100 110 0 12 1 6 1 2 4 8 16 32 +168 -100 120 0 12 1 6 1 2 4 8 16 32 +169 -130 90 0 8 1 6 1 2 4 8 16 32 +170 -130 110 0 8 1 6 1 2 4 8 16 32 +171 -130 130 0 8 1 6 1 2 4 8 16 32 +172 -110 90 0 8 1 6 1 2 4 8 16 32 +173 -110 130 0 8 1 6 1 2 4 8 16 32 +174 -90 90 0 8 1 6 1 2 4 8 16 32 +175 -90 110 0 8 1 6 1 2 4 8 16 32 +176 -90 130 0 8 1 6 1 2 4 8 16 32 +177 -140 80 0 4 1 6 1 2 4 8 16 32 +178 -140 110 0 4 1 6 1 2 4 8 16 32 +179 -140 140 0 4 1 6 1 2 4 8 16 32 +180 -110 80 0 4 1 6 1 2 4 8 16 32 +181 -110 140 0 4 1 6 1 2 4 8 16 32 +182 -80 80 0 4 1 6 1 2 4 8 16 32 +183 -80 110 0 4 1 6 1 2 4 8 16 32 +184 -80 140 0 4 1 6 1 2 4 8 16 32 +185 -150 70 0 2 1 6 1 2 4 8 16 32 +186 -150 110 0 2 1 6 1 2 4 8 16 32 +187 -150 150 0 2 1 6 1 2 4 8 16 32 +188 -110 70 0 2 1 6 1 2 4 8 16 32 +189 -110 150 0 2 1 6 1 2 4 8 16 32 +190 -70 70 0 2 1 6 1 2 4 8 16 32 +191 -70 110 0 2 1 6 1 2 4 8 16 32 +192 -70 150 0 2 1 6 1 2 4 8 16 32 +193 -160 60 0 1 1 6 1 2 4 8 16 32 +194 -160 110 0 1 1 6 1 2 4 8 16 32 +195 -160 160 0 1 1 6 1 2 4 8 16 32 +196 -110 60 0 1 1 6 1 2 4 8 16 32 +197 -110 160 0 1 1 6 1 2 4 8 16 32 +198 -60 60 0 1 1 6 1 2 4 8 16 32 +199 -60 110 0 1 1 6 1 2 4 8 16 32 +200 -60 160 0 1 1 6 1 2 4 8 16 32 +201 -120 -10 0 12 1 6 1 2 4 8 16 32 +202 -120 0 0 12 1 6 1 2 4 8 16 32 +203 -120 10 0 12 1 6 1 2 4 8 16 32 +204 -110 -10 0 12 1 6 1 2 4 8 16 32 +205 -110 10 0 12 1 6 1 2 4 8 16 32 +206 -100 -10 0 12 1 6 1 2 4 8 16 32 +207 -100 0 0 12 1 6 1 2 4 8 16 32 +208 -100 10 0 12 1 6 1 2 4 8 16 32 +209 -130 -20 0 8 1 6 1 2 4 8 16 32 +210 -130 0 0 8 1 6 1 2 4 8 16 32 +211 -130 20 0 8 1 6 1 2 4 8 16 32 +212 -110 -20 0 8 1 6 1 2 4 8 16 32 +213 -110 20 0 8 1 6 1 2 4 8 16 32 +214 -90 -20 0 8 1 6 1 2 4 8 16 32 +215 -90 0 0 8 1 6 1 2 4 8 16 32 +216 -90 20 0 8 1 6 1 2 4 8 16 32 +217 -140 -30 0 4 1 6 1 2 4 8 16 32 +218 -140 0 0 4 1 6 1 2 4 8 16 32 +219 -140 30 0 4 1 6 1 2 4 8 16 32 +220 -110 -30 0 4 1 6 1 2 4 8 16 32 +221 -110 30 0 4 1 6 1 2 4 8 16 32 +222 -80 -30 0 4 1 6 1 2 4 8 16 32 +223 -80 0 0 4 1 6 1 2 4 8 16 32 +224 -80 30 0 4 1 6 1 2 4 8 16 32 +225 -150 -40 0 2 1 6 1 2 4 8 16 32 +226 -150 0 0 2 1 6 1 2 4 8 16 32 +227 -150 40 0 2 1 6 1 2 4 8 16 32 +228 -110 -40 0 2 1 6 1 2 4 8 16 32 +229 -110 40 0 2 1 6 1 2 4 8 16 32 +230 -70 -40 0 2 1 6 1 2 4 8 16 32 +231 -70 0 0 2 1 6 1 2 4 8 16 32 +232 -70 40 0 2 1 6 1 2 4 8 16 32 +233 -160 -50 0 1 1 6 1 2 4 8 16 32 +234 -160 0 0 1 1 6 1 2 4 8 16 32 +235 -160 50 0 1 1 6 1 2 4 8 16 32 +236 -110 -50 0 1 1 6 1 2 4 8 16 32 +237 -110 50 0 1 1 6 1 2 4 8 16 32 +238 -60 -50 0 1 1 6 1 2 4 8 16 32 +239 -60 0 0 1 1 6 1 2 4 8 16 32 +240 -60 50 0 1 1 6 1 2 4 8 16 32 +241 0 0 0 0 0 0 +242 110 0 0 0 0 0 +243 110 110 0 0 0 0 +244 0 110 0 0 0 0 +245 -110 110 0 0 0 0 +246 -110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p19.res b/jsprit-instances/instances/cordeau/p19.res new file mode 100644 index 00000000..2de5f079 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p19.res @@ -0,0 +1,25 @@ +3827.06 +1 1 196.08 58 0 3 11 19 27 35 153 145 156 37 29 21 13 5 0 +1 2 196.08 58 0 2 10 18 26 34 239 230 238 33 25 17 9 1 0 +1 3 128.48 51 0 6 14 22 36 28 20 12 4 0 +1 4 96.57 46 0 8 16 31 23 15 7 0 +2 1 170.71 54 0 46 54 62 70 78 76 68 60 52 44 0 +2 2 128.48 51 0 48 56 64 79 71 63 55 47 0 +2 3 198.99 60 0 43 51 59 67 75 113 105 97 69 61 53 45 0 +2 4 196.08 58 0 42 50 58 66 74 39 30 38 73 65 57 49 41 0 +3 1 170.71 54 0 88 96 104 112 120 119 111 103 95 87 0 +3 2 128.48 51 0 85 93 101 109 117 99 91 83 0 +3 3 96.57 46 0 82 90 98 106 89 81 0 +3 4 196.08 58 0 84 92 100 108 116 77 72 80 118 110 102 94 86 0 +4 1 196.08 58 0 127 135 143 151 159 114 107 115 160 152 144 136 128 0 +4 2 128.48 51 0 123 131 139 157 149 141 133 125 0 +4 3 114.05 50 0 121 129 137 146 138 130 122 0 +4 4 198.99 60 0 126 134 142 150 158 40 32 24 148 140 132 124 0 +5 1 196.08 58 0 167 175 183 191 199 154 147 155 200 192 184 176 168 0 +5 2 170.71 54 0 163 171 179 187 195 197 189 181 173 165 0 +5 3 128.48 51 0 161 169 177 194 186 178 170 162 0 +5 4 198.99 60 0 166 174 182 190 198 240 232 224 188 180 172 164 0 +6 1 170.71 54 0 201 209 217 225 233 234 226 218 210 202 0 +6 2 128.48 51 0 206 214 222 236 228 220 212 204 0 +6 3 96.57 46 0 208 216 231 223 215 207 0 +6 4 196.08 58 0 203 211 219 227 235 193 185 196 237 229 221 213 205 0 diff --git a/jsprit-instances/instances/cordeau/p20 b/jsprit-instances/instances/cordeau/p20 new file mode 100644 index 00000000..2b0df10e --- /dev/null +++ b/jsprit-instances/instances/cordeau/p20 @@ -0,0 +1,253 @@ +2 5 240 6 +180 60 +180 60 +180 60 +180 60 +180 60 +180 60 + 1 -10 -10 0 12 1 6 1 2 4 8 16 32 + 2 -10 0 0 12 1 6 1 2 4 8 16 32 + 3 -10 10 0 12 1 6 1 2 4 8 16 32 + 4 0 -10 0 12 1 6 1 2 4 8 16 32 + 5 0 10 0 12 1 6 1 2 4 8 16 32 + 6 10 -10 0 12 1 6 1 2 4 8 16 32 + 7 10 0 0 12 1 6 1 2 4 8 16 32 + 8 10 10 0 12 1 6 1 2 4 8 16 32 + 9 -20 -20 0 8 1 6 1 2 4 8 16 32 + 10 -20 0 0 8 1 6 1 2 4 8 16 32 + 11 -20 20 0 8 1 6 1 2 4 8 16 32 + 12 0 -20 0 8 1 6 1 2 4 8 16 32 + 13 0 20 0 8 1 6 1 2 4 8 16 32 + 14 20 -20 0 8 1 6 1 2 4 8 16 32 + 15 20 0 0 8 1 6 1 2 4 8 16 32 + 16 20 20 0 8 1 6 1 2 4 8 16 32 + 17 -30 -30 0 4 1 6 1 2 4 8 16 32 + 18 -30 0 0 4 1 6 1 2 4 8 16 32 + 19 -30 30 0 4 1 6 1 2 4 8 16 32 + 20 0 -30 0 4 1 6 1 2 4 8 16 32 + 21 0 30 0 4 1 6 1 2 4 8 16 32 + 22 30 -30 0 4 1 6 1 2 4 8 16 32 + 23 30 0 0 4 1 6 1 2 4 8 16 32 + 24 30 30 0 4 1 6 1 2 4 8 16 32 + 25 -40 -40 0 2 1 6 1 2 4 8 16 32 + 26 -40 0 0 2 1 6 1 2 4 8 16 32 + 27 -40 40 0 2 1 6 1 2 4 8 16 32 + 28 0 -40 0 2 1 6 1 2 4 8 16 32 + 29 0 40 0 2 1 6 1 2 4 8 16 32 + 30 40 -40 0 2 1 6 1 2 4 8 16 32 + 31 40 0 0 2 1 6 1 2 4 8 16 32 + 32 40 40 0 2 1 6 1 2 4 8 16 32 + 33 -50 -50 0 1 1 6 1 2 4 8 16 32 + 34 -50 0 0 1 1 6 1 2 4 8 16 32 + 35 -50 50 0 1 1 6 1 2 4 8 16 32 + 36 0 -50 0 1 1 6 1 2 4 8 16 32 + 37 0 50 0 1 1 6 1 2 4 8 16 32 + 38 50 -50 0 1 1 6 1 2 4 8 16 32 + 39 50 0 0 1 1 6 1 2 4 8 16 32 + 40 50 50 0 1 1 6 1 2 4 8 16 32 + 41 100 -10 0 12 1 6 1 2 4 8 16 32 + 42 100 0 0 12 1 6 1 2 4 8 16 32 + 43 100 10 0 12 1 6 1 2 4 8 16 32 + 44 110 -10 0 12 1 6 1 2 4 8 16 32 + 45 110 10 0 12 1 6 1 2 4 8 16 32 + 46 120 -10 0 12 1 6 1 2 4 8 16 32 + 47 120 0 0 12 1 6 1 2 4 8 16 32 + 48 120 10 0 12 1 6 1 2 4 8 16 32 + 49 90 -20 0 8 1 6 1 2 4 8 16 32 + 50 90 0 0 8 1 6 1 2 4 8 16 32 + 51 90 20 0 8 1 6 1 2 4 8 16 32 + 52 110 -20 0 8 1 6 1 2 4 8 16 32 + 53 110 20 0 8 1 6 1 2 4 8 16 32 + 54 130 -20 0 8 1 6 1 2 4 8 16 32 + 55 130 0 0 8 1 6 1 2 4 8 16 32 + 56 130 20 0 8 1 6 1 2 4 8 16 32 + 57 80 -30 0 4 1 6 1 2 4 8 16 32 + 58 80 0 0 4 1 6 1 2 4 8 16 32 + 59 80 30 0 4 1 6 1 2 4 8 16 32 + 60 110 -30 0 4 1 6 1 2 4 8 16 32 + 61 110 30 0 4 1 6 1 2 4 8 16 32 + 62 140 -30 0 4 1 6 1 2 4 8 16 32 + 63 140 0 0 4 1 6 1 2 4 8 16 32 + 64 140 30 0 4 1 6 1 2 4 8 16 32 + 65 70 -40 0 2 1 6 1 2 4 8 16 32 + 66 70 0 0 2 1 6 1 2 4 8 16 32 + 67 70 40 0 2 1 6 1 2 4 8 16 32 + 68 110 -40 0 2 1 6 1 2 4 8 16 32 + 69 110 40 0 2 1 6 1 2 4 8 16 32 + 70 150 -40 0 2 1 6 1 2 4 8 16 32 + 71 150 0 0 2 1 6 1 2 4 8 16 32 + 72 150 40 0 2 1 6 1 2 4 8 16 32 + 73 60 -50 0 1 1 6 1 2 4 8 16 32 + 74 60 0 0 1 1 6 1 2 4 8 16 32 + 75 60 50 0 1 1 6 1 2 4 8 16 32 + 76 110 -50 0 1 1 6 1 2 4 8 16 32 + 77 110 50 0 1 1 6 1 2 4 8 16 32 + 78 160 -50 0 1 1 6 1 2 4 8 16 32 + 79 160 0 0 1 1 6 1 2 4 8 16 32 + 80 160 50 0 1 1 6 1 2 4 8 16 32 + 81 100 100 0 12 1 6 1 2 4 8 16 32 + 82 100 110 0 12 1 6 1 2 4 8 16 32 + 83 100 120 0 12 1 6 1 2 4 8 16 32 + 84 110 100 0 12 1 6 1 2 4 8 16 32 + 85 110 120 0 12 1 6 1 2 4 8 16 32 + 86 120 100 0 12 1 6 1 2 4 8 16 32 + 87 120 110 0 12 1 6 1 2 4 8 16 32 + 88 120 120 0 12 1 6 1 2 4 8 16 32 + 89 90 90 0 8 1 6 1 2 4 8 16 32 + 90 90 110 0 8 1 6 1 2 4 8 16 32 + 91 90 130 0 8 1 6 1 2 4 8 16 32 + 92 110 90 0 8 1 6 1 2 4 8 16 32 + 93 110 130 0 8 1 6 1 2 4 8 16 32 + 94 130 90 0 8 1 6 1 2 4 8 16 32 + 95 130 110 0 8 1 6 1 2 4 8 16 32 + 96 130 130 0 8 1 6 1 2 4 8 16 32 + 97 80 80 0 4 1 6 1 2 4 8 16 32 + 98 80 110 0 4 1 6 1 2 4 8 16 32 + 99 80 140 0 4 1 6 1 2 4 8 16 32 +100 110 80 0 4 1 6 1 2 4 8 16 32 +101 110 140 0 4 1 6 1 2 4 8 16 32 +102 140 80 0 4 1 6 1 2 4 8 16 32 +103 140 110 0 4 1 6 1 2 4 8 16 32 +104 140 140 0 4 1 6 1 2 4 8 16 32 +105 70 70 0 2 1 6 1 2 4 8 16 32 +106 70 110 0 2 1 6 1 2 4 8 16 32 +107 70 150 0 2 1 6 1 2 4 8 16 32 +108 110 70 0 2 1 6 1 2 4 8 16 32 +109 110 150 0 2 1 6 1 2 4 8 16 32 +110 150 70 0 2 1 6 1 2 4 8 16 32 +111 150 110 0 2 1 6 1 2 4 8 16 32 +112 150 150 0 2 1 6 1 2 4 8 16 32 +113 60 60 0 1 1 6 1 2 4 8 16 32 +114 60 110 0 1 1 6 1 2 4 8 16 32 +115 60 160 0 1 1 6 1 2 4 8 16 32 +116 110 60 0 1 1 6 1 2 4 8 16 32 +117 110 160 0 1 1 6 1 2 4 8 16 32 +118 160 60 0 1 1 6 1 2 4 8 16 32 +119 160 110 0 1 1 6 1 2 4 8 16 32 +120 160 160 0 1 1 6 1 2 4 8 16 32 +121 -10 100 0 12 1 6 1 2 4 8 16 32 +122 -10 110 0 12 1 6 1 2 4 8 16 32 +123 -10 120 0 12 1 6 1 2 4 8 16 32 +124 0 100 0 12 1 6 1 2 4 8 16 32 +125 0 120 0 12 1 6 1 2 4 8 16 32 +126 10 100 0 12 1 6 1 2 4 8 16 32 +127 10 110 0 12 1 6 1 2 4 8 16 32 +128 10 120 0 12 1 6 1 2 4 8 16 32 +129 -20 90 0 8 1 6 1 2 4 8 16 32 +130 -20 110 0 8 1 6 1 2 4 8 16 32 +131 -20 130 0 8 1 6 1 2 4 8 16 32 +132 0 90 0 8 1 6 1 2 4 8 16 32 +133 0 130 0 8 1 6 1 2 4 8 16 32 +134 20 90 0 8 1 6 1 2 4 8 16 32 +135 20 110 0 8 1 6 1 2 4 8 16 32 +136 20 130 0 8 1 6 1 2 4 8 16 32 +137 -30 80 0 4 1 6 1 2 4 8 16 32 +138 -30 110 0 4 1 6 1 2 4 8 16 32 +139 -30 140 0 4 1 6 1 2 4 8 16 32 +140 0 80 0 4 1 6 1 2 4 8 16 32 +141 0 140 0 4 1 6 1 2 4 8 16 32 +142 30 80 0 4 1 6 1 2 4 8 16 32 +143 30 110 0 4 1 6 1 2 4 8 16 32 +144 30 140 0 4 1 6 1 2 4 8 16 32 +145 -40 70 0 2 1 6 1 2 4 8 16 32 +146 -40 110 0 2 1 6 1 2 4 8 16 32 +147 -40 150 0 2 1 6 1 2 4 8 16 32 +148 0 70 0 2 1 6 1 2 4 8 16 32 +149 0 150 0 2 1 6 1 2 4 8 16 32 +150 40 70 0 2 1 6 1 2 4 8 16 32 +151 40 110 0 2 1 6 1 2 4 8 16 32 +152 40 150 0 2 1 6 1 2 4 8 16 32 +153 -50 60 0 1 1 6 1 2 4 8 16 32 +154 -50 110 0 1 1 6 1 2 4 8 16 32 +155 -50 160 0 1 1 6 1 2 4 8 16 32 +156 0 60 0 1 1 6 1 2 4 8 16 32 +157 0 160 0 1 1 6 1 2 4 8 16 32 +158 50 60 0 1 1 6 1 2 4 8 16 32 +159 50 110 0 1 1 6 1 2 4 8 16 32 +160 50 160 0 1 1 6 1 2 4 8 16 32 +161 -120 100 0 12 1 6 1 2 4 8 16 32 +162 -120 110 0 12 1 6 1 2 4 8 16 32 +163 -120 120 0 12 1 6 1 2 4 8 16 32 +164 -110 100 0 12 1 6 1 2 4 8 16 32 +165 -110 120 0 12 1 6 1 2 4 8 16 32 +166 -100 100 0 12 1 6 1 2 4 8 16 32 +167 -100 110 0 12 1 6 1 2 4 8 16 32 +168 -100 120 0 12 1 6 1 2 4 8 16 32 +169 -130 90 0 8 1 6 1 2 4 8 16 32 +170 -130 110 0 8 1 6 1 2 4 8 16 32 +171 -130 130 0 8 1 6 1 2 4 8 16 32 +172 -110 90 0 8 1 6 1 2 4 8 16 32 +173 -110 130 0 8 1 6 1 2 4 8 16 32 +174 -90 90 0 8 1 6 1 2 4 8 16 32 +175 -90 110 0 8 1 6 1 2 4 8 16 32 +176 -90 130 0 8 1 6 1 2 4 8 16 32 +177 -140 80 0 4 1 6 1 2 4 8 16 32 +178 -140 110 0 4 1 6 1 2 4 8 16 32 +179 -140 140 0 4 1 6 1 2 4 8 16 32 +180 -110 80 0 4 1 6 1 2 4 8 16 32 +181 -110 140 0 4 1 6 1 2 4 8 16 32 +182 -80 80 0 4 1 6 1 2 4 8 16 32 +183 -80 110 0 4 1 6 1 2 4 8 16 32 +184 -80 140 0 4 1 6 1 2 4 8 16 32 +185 -150 70 0 2 1 6 1 2 4 8 16 32 +186 -150 110 0 2 1 6 1 2 4 8 16 32 +187 -150 150 0 2 1 6 1 2 4 8 16 32 +188 -110 70 0 2 1 6 1 2 4 8 16 32 +189 -110 150 0 2 1 6 1 2 4 8 16 32 +190 -70 70 0 2 1 6 1 2 4 8 16 32 +191 -70 110 0 2 1 6 1 2 4 8 16 32 +192 -70 150 0 2 1 6 1 2 4 8 16 32 +193 -160 60 0 1 1 6 1 2 4 8 16 32 +194 -160 110 0 1 1 6 1 2 4 8 16 32 +195 -160 160 0 1 1 6 1 2 4 8 16 32 +196 -110 60 0 1 1 6 1 2 4 8 16 32 +197 -110 160 0 1 1 6 1 2 4 8 16 32 +198 -60 60 0 1 1 6 1 2 4 8 16 32 +199 -60 110 0 1 1 6 1 2 4 8 16 32 +200 -60 160 0 1 1 6 1 2 4 8 16 32 +201 -120 -10 0 12 1 6 1 2 4 8 16 32 +202 -120 0 0 12 1 6 1 2 4 8 16 32 +203 -120 10 0 12 1 6 1 2 4 8 16 32 +204 -110 -10 0 12 1 6 1 2 4 8 16 32 +205 -110 10 0 12 1 6 1 2 4 8 16 32 +206 -100 -10 0 12 1 6 1 2 4 8 16 32 +207 -100 0 0 12 1 6 1 2 4 8 16 32 +208 -100 10 0 12 1 6 1 2 4 8 16 32 +209 -130 -20 0 8 1 6 1 2 4 8 16 32 +210 -130 0 0 8 1 6 1 2 4 8 16 32 +211 -130 20 0 8 1 6 1 2 4 8 16 32 +212 -110 -20 0 8 1 6 1 2 4 8 16 32 +213 -110 20 0 8 1 6 1 2 4 8 16 32 +214 -90 -20 0 8 1 6 1 2 4 8 16 32 +215 -90 0 0 8 1 6 1 2 4 8 16 32 +216 -90 20 0 8 1 6 1 2 4 8 16 32 +217 -140 -30 0 4 1 6 1 2 4 8 16 32 +218 -140 0 0 4 1 6 1 2 4 8 16 32 +219 -140 30 0 4 1 6 1 2 4 8 16 32 +220 -110 -30 0 4 1 6 1 2 4 8 16 32 +221 -110 30 0 4 1 6 1 2 4 8 16 32 +222 -80 -30 0 4 1 6 1 2 4 8 16 32 +223 -80 0 0 4 1 6 1 2 4 8 16 32 +224 -80 30 0 4 1 6 1 2 4 8 16 32 +225 -150 -40 0 2 1 6 1 2 4 8 16 32 +226 -150 0 0 2 1 6 1 2 4 8 16 32 +227 -150 40 0 2 1 6 1 2 4 8 16 32 +228 -110 -40 0 2 1 6 1 2 4 8 16 32 +229 -110 40 0 2 1 6 1 2 4 8 16 32 +230 -70 -40 0 2 1 6 1 2 4 8 16 32 +231 -70 0 0 2 1 6 1 2 4 8 16 32 +232 -70 40 0 2 1 6 1 2 4 8 16 32 +233 -160 -50 0 1 1 6 1 2 4 8 16 32 +234 -160 0 0 1 1 6 1 2 4 8 16 32 +235 -160 50 0 1 1 6 1 2 4 8 16 32 +236 -110 -50 0 1 1 6 1 2 4 8 16 32 +237 -110 50 0 1 1 6 1 2 4 8 16 32 +238 -60 -50 0 1 1 6 1 2 4 8 16 32 +239 -60 0 0 1 1 6 1 2 4 8 16 32 +240 -60 50 0 1 1 6 1 2 4 8 16 32 +241 0 0 0 0 0 0 +242 110 0 0 0 0 0 +243 110 110 0 0 0 0 +244 0 110 0 0 0 0 +245 -110 110 0 0 0 0 +246 -110 0 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p20.res b/jsprit-instances/instances/cordeau/p20.res new file mode 100644 index 00000000..3e2e4195 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p20.res @@ -0,0 +1,25 @@ +4058.07 +1 1 161.29 54 0 1 9 17 25 239 34 26 18 10 2 0 +1 2 170.71 54 0 6 14 22 30 38 36 28 20 12 4 0 +1 3 161.29 54 0 8 16 24 32 74 39 31 23 15 7 0 +1 4 174.56 54 0 3 11 19 27 35 153 29 21 13 5 0 +2 1 174.56 54 0 48 56 64 72 80 118 69 61 53 45 0 +2 2 174.56 54 0 43 51 59 67 75 40 66 58 50 42 0 +2 3 170.71 54 0 41 49 57 65 73 76 68 60 52 44 0 +2 4 170.71 54 0 46 54 62 70 78 79 71 63 55 47 0 +3 1 161.29 54 0 86 94 102 110 77 116 108 100 92 84 0 +3 2 170.71 54 0 88 96 104 112 120 119 111 103 95 87 0 +3 3 170.71 54 0 83 91 99 107 115 117 109 101 93 85 0 +3 4 161.29 54 0 81 89 97 105 159 114 106 98 90 82 0 +4 1 161.29 54 0 123 131 139 147 199 154 146 138 130 122 0 +4 2 161.29 54 0 121 129 137 145 37 156 148 140 132 124 0 +4 3 174.56 54 0 126 134 142 150 158 113 151 143 135 127 0 +4 4 170.71 54 0 125 133 141 149 157 160 152 144 136 128 0 +5 1 170.71 54 0 163 171 179 187 195 197 189 181 173 165 0 +5 2 170.71 54 0 161 169 177 185 193 194 186 178 170 162 0 +5 3 161.29 54 0 166 174 182 190 237 196 188 180 172 164 0 +5 4 174.56 54 0 168 176 184 192 200 155 191 183 175 167 0 +6 1 170.71 54 0 203 211 219 227 235 234 226 218 210 202 0 +6 2 170.71 54 0 201 209 217 225 233 236 228 220 212 204 0 +6 3 174.56 54 0 206 214 222 230 238 33 231 223 215 207 0 +6 4 174.56 54 0 208 216 224 232 240 198 229 221 213 205 0 diff --git a/jsprit-instances/instances/cordeau/p21 b/jsprit-instances/instances/cordeau/p21 new file mode 100644 index 00000000..81eb78b6 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p21 @@ -0,0 +1,379 @@ +2 5 360 9 +0 60 +0 60 +0 60 +0 60 +0 60 +0 60 +0 60 +0 60 +0 60 + 1 -10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 2 -10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 3 -10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 4 0 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 5 0 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 6 10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 7 10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 8 10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 9 -20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 10 -20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 11 -20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 12 0 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 13 0 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 14 20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 15 20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 16 20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 17 -30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 18 -30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 19 -30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 20 0 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 21 0 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 22 30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 23 30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 24 30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 25 -40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 26 -40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 27 -40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 28 0 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 29 0 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 30 40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 31 40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 32 40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 33 -50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 34 -50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 35 -50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 36 0 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 37 0 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 38 50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 39 50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 40 50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 41 100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 42 100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 43 100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 44 110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 45 110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 46 120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 47 120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 48 120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 49 90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 50 90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 51 90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 52 110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 53 110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 54 130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 55 130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 56 130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 57 80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 58 80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 59 80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 60 110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 61 110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 62 140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 63 140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 64 140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 65 70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 66 70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 67 70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 68 110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 69 110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 70 150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 71 150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 72 150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 73 60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 74 60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 75 60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 76 110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 77 110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 78 160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 79 160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 80 160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 81 100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 82 100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 83 100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 84 110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 85 110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 86 120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 87 120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 88 120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 89 90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 90 90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 91 90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 92 110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 93 110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 94 130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 95 130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 96 130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 97 80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 + 98 80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 + 99 80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +100 110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +101 110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +102 140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +103 140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +104 140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +105 70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +106 70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +107 70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +108 110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +109 110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +110 150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +111 150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +112 150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +113 60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +114 60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +115 60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +116 110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +117 110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +118 160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +119 160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +120 160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +121 -10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +122 -10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +123 -10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +124 0 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +125 0 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +126 10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +127 10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +128 10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +129 -20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +130 -20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +131 -20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +132 0 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +133 0 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +134 20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +135 20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +136 20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +137 -30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +138 -30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +139 -30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +140 0 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +141 0 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +142 30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +143 30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +144 30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +145 -40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +146 -40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +147 -40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +148 0 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +149 0 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +150 40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +151 40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +152 40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +153 -50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +154 -50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +155 -50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +156 0 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +157 0 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +158 50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +159 50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +160 50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +161 -120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +162 -120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +163 -120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +164 -110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +165 -110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +166 -100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +167 -100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +168 -100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +169 -130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +170 -130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +171 -130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +172 -110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +173 -110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +174 -90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +175 -90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +176 -90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +177 -140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +178 -140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +179 -140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +180 -110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +181 -110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +182 -80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +183 -80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +184 -80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +185 -150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +186 -150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +187 -150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +188 -110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +189 -110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +190 -70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +191 -70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +192 -70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +193 -160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +194 -160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +195 -160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +196 -110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +197 -110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +198 -60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +199 -60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +200 -60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +201 -120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +202 -120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +203 -120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +204 -110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +205 -110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +206 -100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +207 -100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +208 -100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +209 -130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +210 -130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +211 -130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +212 -110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +213 -110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +214 -90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +215 -90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +216 -90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +217 -140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +218 -140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +219 -140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +220 -110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +221 -110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +222 -80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +223 -80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +224 -80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +225 -150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +226 -150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +227 -150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +228 -110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +229 -110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +230 -70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +231 -70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +232 -70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +233 -160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +234 -160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +235 -160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +236 -110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +237 -110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +238 -60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +239 -60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +240 -60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +241 -120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +242 -120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +243 -120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +244 -110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +245 -110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +246 -100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +247 -100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +248 -100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +249 -130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +250 -130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +251 -130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +252 -110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +253 -110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +254 -90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +255 -90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +256 -90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +257 -140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +258 -140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +259 -140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +260 -110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +261 -110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +262 -80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +263 -80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +264 -80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +265 -150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +266 -150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +267 -150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +268 -110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +269 -110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +270 -70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +271 -70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +272 -70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +273 -160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +274 -160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +275 -160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +276 -110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +277 -110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +278 -60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +279 -60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +280 -60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +281 -10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +282 -10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +283 -10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +284 0 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +285 0 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +286 10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +287 10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +288 10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +289 -20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +290 -20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +291 -20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +292 0 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +293 0 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +294 20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +295 20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +296 20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +297 -30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +298 -30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +299 -30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +300 0 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +301 0 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +302 30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +303 30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +304 30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +305 -40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +306 -40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +307 -40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +308 0 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +309 0 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +310 40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +311 40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +312 40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +313 -50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +314 -50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +315 -50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +316 0 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +317 0 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +318 50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +319 50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +320 50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +321 100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +322 100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +323 100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +324 110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +325 110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +326 120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +327 120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +328 120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +329 90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +330 90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +331 90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +332 110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +333 110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +334 130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +335 130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +336 130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +337 80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +338 80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +339 80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +340 110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +341 110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +342 140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +343 140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +344 140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +345 70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +346 70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +347 70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +348 110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +349 110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +350 150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +351 150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +352 150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +353 60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +354 60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +355 60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +356 110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +357 110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +358 160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +359 160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +360 160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +361 0 0 0 0 0 0 +362 110 0 0 0 0 0 +363 110 110 0 0 0 0 +364 0 110 0 0 0 0 +365 -110 110 0 0 0 0 +366 -110 0 0 0 0 0 +367 -110 -110 0 0 0 0 +368 0 -110 0 0 0 0 +369 110 -110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p21.res b/jsprit-instances/instances/cordeau/p21.res new file mode 100644 index 00000000..5395c2b9 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p21.res @@ -0,0 +1,35 @@ +5474.84 +1 1 233.14 60 0 11 19 27 35 240 232 224 216 215 223 231 239 34 26 18 10 0 +1 2 233.14 60 0 9 17 25 33 315 307 299 291 293 301 309 317 36 28 20 12 0 +1 3 54.14 48 0 3 2 1 4 0 +1 4 54.14 48 0 6 7 8 5 0 +1 5 233.14 60 0 13 21 29 37 156 148 140 132 134 142 150 158 40 32 24 16 0 +2 1 221.42 60 0 52 60 68 76 357 349 336 344 352 360 78 70 62 54 46 0 +2 2 188.93 55 0 48 56 64 72 118 80 79 71 63 55 47 0 +2 3 233.14 60 0 50 58 66 74 39 31 23 15 14 22 30 38 73 65 57 49 0 +2 4 233.14 60 0 53 61 69 77 116 108 100 92 89 97 105 113 75 67 59 51 0 +2 5 60.00 60 0 45 43 42 41 44 0 +3 1 86.50 60 0 84 81 82 90 98 83 0 +3 2 147.80 53 0 87 95 103 111 119 110 102 94 86 0 +3 3 170.71 54 0 88 96 104 112 120 117 109 101 93 85 0 +4 1 60.00 60 0 122 121 124 126 127 0 +4 2 221.42 60 0 128 136 144 152 160 115 107 99 91 106 114 159 151 143 135 0 +4 3 233.14 60 0 129 137 145 153 198 190 182 174 175 183 191 199 154 146 138 130 0 +4 4 188.93 55 0 123 131 139 147 200 155 157 149 141 133 125 0 +5 1 147.80 53 0 168 176 184 192 197 189 181 173 165 0 +5 2 86.50 60 0 161 164 172 180 166 167 0 +5 3 170.71 54 0 163 171 179 187 195 194 186 178 170 162 0 +6 1 233.14 60 0 212 220 228 236 277 269 261 253 256 264 272 280 238 230 222 214 0 +6 2 221.42 60 0 213 221 229 237 196 188 169 177 185 193 235 227 219 211 203 0 +6 3 60.00 60 0 204 206 207 208 205 0 +6 4 147.80 53 0 201 209 217 225 234 226 218 210 202 0 +7 1 86.50 60 0 245 248 247 255 263 246 0 +7 2 188.93 55 0 242 250 258 266 274 275 233 267 259 251 243 0 +7 3 170.71 54 0 241 249 257 265 273 276 268 260 252 244 0 +8 1 233.14 60 0 295 303 311 319 354 346 338 330 331 339 347 355 320 312 304 296 0 +8 2 221.42 60 0 290 298 306 314 279 271 254 262 270 278 313 305 297 289 281 0 +8 3 60.00 60 0 287 288 285 283 282 0 +8 4 188.93 55 0 286 294 302 310 353 318 316 308 300 292 284 0 +9 1 170.71 54 0 326 334 342 350 358 359 351 343 335 327 0 +9 2 147.80 53 0 321 329 337 345 356 348 340 332 324 0 +9 3 86.50 60 0 328 341 333 325 323 322 0 diff --git a/jsprit-instances/instances/cordeau/p22 b/jsprit-instances/instances/cordeau/p22 new file mode 100644 index 00000000..8a58a490 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p22 @@ -0,0 +1,379 @@ +2 5 360 9 +200 60 +200 60 +200 60 +200 60 +200 60 +200 60 +200 60 +200 60 +200 60 + 1 -10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 2 -10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 3 -10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 4 0 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 5 0 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 6 10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 7 10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 8 10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 9 -20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 10 -20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 11 -20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 12 0 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 13 0 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 14 20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 15 20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 16 20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 17 -30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 18 -30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 19 -30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 20 0 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 21 0 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 22 30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 23 30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 24 30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 25 -40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 26 -40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 27 -40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 28 0 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 29 0 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 30 40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 31 40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 32 40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 33 -50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 34 -50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 35 -50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 36 0 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 37 0 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 38 50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 39 50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 40 50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 41 100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 42 100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 43 100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 44 110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 45 110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 46 120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 47 120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 48 120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 49 90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 50 90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 51 90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 52 110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 53 110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 54 130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 55 130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 56 130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 57 80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 58 80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 59 80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 60 110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 61 110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 62 140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 63 140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 64 140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 65 70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 66 70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 67 70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 68 110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 69 110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 70 150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 71 150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 72 150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 73 60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 74 60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 75 60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 76 110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 77 110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 78 160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 79 160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 80 160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 81 100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 82 100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 83 100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 84 110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 85 110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 86 120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 87 120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 88 120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 89 90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 90 90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 91 90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 92 110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 93 110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 94 130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 95 130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 96 130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 97 80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 + 98 80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 + 99 80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +100 110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +101 110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +102 140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +103 140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +104 140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +105 70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +106 70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +107 70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +108 110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +109 110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +110 150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +111 150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +112 150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +113 60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +114 60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +115 60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +116 110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +117 110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +118 160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +119 160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +120 160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +121 -10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +122 -10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +123 -10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +124 0 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +125 0 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +126 10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +127 10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +128 10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +129 -20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +130 -20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +131 -20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +132 0 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +133 0 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +134 20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +135 20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +136 20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +137 -30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +138 -30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +139 -30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +140 0 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +141 0 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +142 30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +143 30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +144 30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +145 -40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +146 -40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +147 -40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +148 0 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +149 0 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +150 40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +151 40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +152 40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +153 -50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +154 -50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +155 -50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +156 0 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +157 0 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +158 50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +159 50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +160 50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +161 -120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +162 -120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +163 -120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +164 -110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +165 -110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +166 -100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +167 -100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +168 -100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +169 -130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +170 -130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +171 -130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +172 -110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +173 -110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +174 -90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +175 -90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +176 -90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +177 -140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +178 -140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +179 -140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +180 -110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +181 -110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +182 -80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +183 -80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +184 -80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +185 -150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +186 -150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +187 -150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +188 -110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +189 -110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +190 -70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +191 -70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +192 -70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +193 -160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +194 -160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +195 -160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +196 -110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +197 -110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +198 -60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +199 -60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +200 -60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +201 -120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +202 -120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +203 -120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +204 -110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +205 -110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +206 -100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +207 -100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +208 -100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +209 -130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +210 -130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +211 -130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +212 -110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +213 -110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +214 -90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +215 -90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +216 -90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +217 -140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +218 -140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +219 -140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +220 -110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +221 -110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +222 -80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +223 -80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +224 -80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +225 -150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +226 -150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +227 -150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +228 -110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +229 -110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +230 -70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +231 -70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +232 -70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +233 -160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +234 -160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +235 -160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +236 -110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +237 -110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +238 -60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +239 -60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +240 -60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +241 -120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +242 -120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +243 -120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +244 -110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +245 -110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +246 -100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +247 -100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +248 -100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +249 -130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +250 -130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +251 -130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +252 -110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +253 -110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +254 -90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +255 -90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +256 -90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +257 -140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +258 -140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +259 -140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +260 -110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +261 -110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +262 -80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +263 -80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +264 -80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +265 -150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +266 -150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +267 -150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +268 -110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +269 -110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +270 -70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +271 -70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +272 -70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +273 -160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +274 -160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +275 -160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +276 -110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +277 -110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +278 -60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +279 -60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +280 -60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +281 -10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +282 -10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +283 -10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +284 0 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +285 0 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +286 10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +287 10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +288 10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +289 -20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +290 -20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +291 -20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +292 0 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +293 0 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +294 20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +295 20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +296 20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +297 -30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +298 -30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +299 -30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +300 0 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +301 0 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +302 30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +303 30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +304 30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +305 -40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +306 -40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +307 -40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +308 0 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +309 0 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +310 40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +311 40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +312 40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +313 -50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +314 -50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +315 -50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +316 0 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +317 0 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +318 50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +319 50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +320 50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +321 100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +322 100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +323 100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +324 110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +325 110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +326 120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +327 120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +328 120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +329 90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +330 90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +331 90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +332 110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +333 110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +334 130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +335 130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +336 130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +337 80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +338 80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +339 80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +340 110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +341 110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +342 140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +343 140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +344 140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +345 70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +346 70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +347 70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +348 110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +349 110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +350 150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +351 150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +352 150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +353 60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +354 60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +355 60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +356 110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +357 110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +358 160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +359 160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +360 160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +361 0 0 0 0 0 0 +362 110 0 0 0 0 0 +363 110 110 0 0 0 0 +364 0 110 0 0 0 0 +365 -110 110 0 0 0 0 +366 -110 0 0 0 0 0 +367 -110 -110 0 0 0 0 +368 0 -110 0 0 0 0 +369 110 -110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p22.res b/jsprit-instances/instances/cordeau/p22.res new file mode 100644 index 00000000..facb7d6a --- /dev/null +++ b/jsprit-instances/instances/cordeau/p22.res @@ -0,0 +1,37 @@ +5702.16 +1 1 196.08 58 0 6 14 22 30 38 320 312 317 36 28 20 12 4 0 +1 2 114.05 50 0 2 10 18 26 17 9 1 0 +1 3 114.05 50 0 7 15 23 31 24 16 8 0 +1 4 114.05 50 0 5 13 21 29 19 11 3 0 +2 1 198.99 60 0 41 49 57 65 73 355 347 339 68 60 52 44 0 +2 2 196.08 58 0 45 53 61 69 77 116 110 118 80 72 64 56 48 0 +2 3 128.48 51 0 47 55 63 71 79 62 54 46 0 +2 4 196.08 58 0 43 51 59 67 75 40 32 39 74 66 58 50 42 0 +3 1 196.08 58 0 82 90 98 106 114 159 152 160 115 107 99 91 83 0 +3 2 128.48 51 0 86 94 102 119 111 103 95 87 0 +3 3 170.71 54 0 88 96 104 112 120 117 109 101 93 85 0 +3 4 96.57 46 0 81 89 108 100 92 84 0 +4 1 128.48 51 0 125 133 141 149 157 144 136 128 0 +4 2 198.99 60 0 127 135 143 151 97 105 113 158 150 142 134 126 0 +4 3 196.08 58 0 121 129 137 145 153 35 27 37 156 148 140 132 124 0 +4 4 196.08 58 0 122 130 138 146 154 199 192 200 155 147 139 131 123 0 +5 1 96.57 46 0 167 175 183 191 174 166 0 +5 2 128.48 51 0 165 173 181 189 197 184 176 168 0 +5 3 196.08 58 0 164 172 180 188 196 237 227 235 193 185 177 169 161 0 +5 4 170.71 54 0 163 171 179 187 195 194 186 178 170 162 0 +6 1 128.48 51 0 202 210 218 226 234 219 211 203 0 +6 2 198.99 60 0 205 213 221 229 182 190 198 240 232 224 216 208 0 +6 3 196.08 58 0 204 212 220 228 236 277 267 275 233 225 217 209 201 0 +6 4 196.08 58 0 206 214 222 230 238 33 25 34 239 231 223 215 207 0 +7 1 96.57 46 0 248 256 269 261 253 245 0 +7 2 128.48 51 0 242 250 258 266 274 259 251 243 0 +7 3 170.71 54 0 241 249 257 265 273 276 268 260 252 244 0 +7 4 196.08 58 0 246 254 262 270 278 313 305 314 279 271 263 255 247 0 +8 1 196.08 58 0 287 295 303 311 319 354 345 353 318 310 302 294 286 0 +8 2 114.05 50 0 285 293 301 309 304 296 288 0 +8 3 198.99 60 0 282 290 298 306 264 272 280 315 307 299 291 283 0 +8 4 128.48 51 0 281 289 297 316 308 300 292 284 0 +9 1 128.48 51 0 321 329 337 356 348 340 332 324 0 +9 2 96.57 46 0 322 330 338 346 331 323 0 +9 3 196.08 58 0 325 333 341 349 357 76 70 78 360 352 344 336 328 0 +9 4 170.71 54 0 327 335 343 351 359 358 350 342 334 326 0 diff --git a/jsprit-instances/instances/cordeau/p23 b/jsprit-instances/instances/cordeau/p23 new file mode 100644 index 00000000..816235fc --- /dev/null +++ b/jsprit-instances/instances/cordeau/p23 @@ -0,0 +1,379 @@ +2 5 360 9 +180 60 +180 60 +180 60 +180 60 +180 60 +180 60 +180 60 +180 60 +180 60 + 1 -10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 2 -10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 3 -10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 4 0 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 5 0 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 6 10 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 7 10 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 8 10 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 9 -20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 10 -20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 11 -20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 12 0 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 13 0 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 14 20 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 15 20 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 16 20 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 17 -30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 18 -30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 19 -30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 20 0 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 21 0 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 22 30 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 23 30 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 24 30 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 25 -40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 26 -40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 27 -40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 28 0 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 29 0 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 30 40 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 31 40 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 32 40 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 33 -50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 34 -50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 35 -50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 36 0 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 37 0 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 38 50 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 39 50 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 40 50 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 41 100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 42 100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 43 100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 44 110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 45 110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 46 120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 47 120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 + 48 120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 + 49 90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 50 90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 51 90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 52 110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 53 110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 54 130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 55 130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 + 56 130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 + 57 80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 58 80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 59 80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 60 110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 61 110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 62 140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 63 140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 + 64 140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 + 65 70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 66 70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 67 70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 68 110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 69 110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 70 150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 71 150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 + 72 150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 + 73 60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 74 60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 75 60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 76 110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 77 110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 78 160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 79 160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 + 80 160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 + 81 100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 82 100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 83 100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 84 110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 85 110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 86 120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 + 87 120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 + 88 120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 + 89 90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 90 90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 91 90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 92 110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 93 110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 94 130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 + 95 130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 + 96 130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 + 97 80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 + 98 80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 + 99 80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +100 110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +101 110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +102 140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +103 140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +104 140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +105 70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +106 70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +107 70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +108 110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +109 110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +110 150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +111 150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +112 150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +113 60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +114 60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +115 60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +116 110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +117 110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +118 160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +119 160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +120 160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +121 -10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +122 -10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +123 -10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +124 0 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +125 0 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +126 10 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +127 10 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +128 10 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +129 -20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +130 -20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +131 -20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +132 0 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +133 0 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +134 20 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +135 20 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +136 20 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +137 -30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +138 -30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +139 -30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +140 0 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +141 0 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +142 30 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +143 30 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +144 30 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +145 -40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +146 -40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +147 -40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +148 0 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +149 0 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +150 40 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +151 40 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +152 40 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +153 -50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +154 -50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +155 -50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +156 0 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +157 0 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +158 50 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +159 50 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +160 50 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +161 -120 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +162 -120 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +163 -120 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +164 -110 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +165 -110 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +166 -100 100 0 12 1 9 1 2 4 8 16 32 64 128 256 +167 -100 110 0 12 1 9 1 2 4 8 16 32 64 128 256 +168 -100 120 0 12 1 9 1 2 4 8 16 32 64 128 256 +169 -130 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +170 -130 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +171 -130 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +172 -110 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +173 -110 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +174 -90 90 0 8 1 9 1 2 4 8 16 32 64 128 256 +175 -90 110 0 8 1 9 1 2 4 8 16 32 64 128 256 +176 -90 130 0 8 1 9 1 2 4 8 16 32 64 128 256 +177 -140 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +178 -140 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +179 -140 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +180 -110 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +181 -110 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +182 -80 80 0 4 1 9 1 2 4 8 16 32 64 128 256 +183 -80 110 0 4 1 9 1 2 4 8 16 32 64 128 256 +184 -80 140 0 4 1 9 1 2 4 8 16 32 64 128 256 +185 -150 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +186 -150 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +187 -150 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +188 -110 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +189 -110 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +190 -70 70 0 2 1 9 1 2 4 8 16 32 64 128 256 +191 -70 110 0 2 1 9 1 2 4 8 16 32 64 128 256 +192 -70 150 0 2 1 9 1 2 4 8 16 32 64 128 256 +193 -160 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +194 -160 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +195 -160 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +196 -110 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +197 -110 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +198 -60 60 0 1 1 9 1 2 4 8 16 32 64 128 256 +199 -60 110 0 1 1 9 1 2 4 8 16 32 64 128 256 +200 -60 160 0 1 1 9 1 2 4 8 16 32 64 128 256 +201 -120 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +202 -120 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +203 -120 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +204 -110 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +205 -110 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +206 -100 -10 0 12 1 9 1 2 4 8 16 32 64 128 256 +207 -100 0 0 12 1 9 1 2 4 8 16 32 64 128 256 +208 -100 10 0 12 1 9 1 2 4 8 16 32 64 128 256 +209 -130 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +210 -130 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +211 -130 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +212 -110 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +213 -110 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +214 -90 -20 0 8 1 9 1 2 4 8 16 32 64 128 256 +215 -90 0 0 8 1 9 1 2 4 8 16 32 64 128 256 +216 -90 20 0 8 1 9 1 2 4 8 16 32 64 128 256 +217 -140 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +218 -140 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +219 -140 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +220 -110 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +221 -110 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +222 -80 -30 0 4 1 9 1 2 4 8 16 32 64 128 256 +223 -80 0 0 4 1 9 1 2 4 8 16 32 64 128 256 +224 -80 30 0 4 1 9 1 2 4 8 16 32 64 128 256 +225 -150 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +226 -150 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +227 -150 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +228 -110 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +229 -110 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +230 -70 -40 0 2 1 9 1 2 4 8 16 32 64 128 256 +231 -70 0 0 2 1 9 1 2 4 8 16 32 64 128 256 +232 -70 40 0 2 1 9 1 2 4 8 16 32 64 128 256 +233 -160 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +234 -160 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +235 -160 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +236 -110 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +237 -110 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +238 -60 -50 0 1 1 9 1 2 4 8 16 32 64 128 256 +239 -60 0 0 1 1 9 1 2 4 8 16 32 64 128 256 +240 -60 50 0 1 1 9 1 2 4 8 16 32 64 128 256 +241 -120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +242 -120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +243 -120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +244 -110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +245 -110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +246 -100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +247 -100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +248 -100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +249 -130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +250 -130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +251 -130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +252 -110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +253 -110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +254 -90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +255 -90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +256 -90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +257 -140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +258 -140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +259 -140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +260 -110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +261 -110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +262 -80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +263 -80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +264 -80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +265 -150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +266 -150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +267 -150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +268 -110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +269 -110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +270 -70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +271 -70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +272 -70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +273 -160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +274 -160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +275 -160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +276 -110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +277 -110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +278 -60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +279 -60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +280 -60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +281 -10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +282 -10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +283 -10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +284 0 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +285 0 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +286 10 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +287 10 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +288 10 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +289 -20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +290 -20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +291 -20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +292 0 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +293 0 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +294 20 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +295 20 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +296 20 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +297 -30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +298 -30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +299 -30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +300 0 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +301 0 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +302 30 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +303 30 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +304 30 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +305 -40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +306 -40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +307 -40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +308 0 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +309 0 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +310 40 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +311 40 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +312 40 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +313 -50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +314 -50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +315 -50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +316 0 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +317 0 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +318 50 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +319 50 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +320 50 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +321 100 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +322 100 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +323 100 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +324 110 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +325 110 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +326 120 -120 0 12 1 9 1 2 4 8 16 32 64 128 256 +327 120 -110 0 12 1 9 1 2 4 8 16 32 64 128 256 +328 120 -100 0 12 1 9 1 2 4 8 16 32 64 128 256 +329 90 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +330 90 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +331 90 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +332 110 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +333 110 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +334 130 -130 0 8 1 9 1 2 4 8 16 32 64 128 256 +335 130 -110 0 8 1 9 1 2 4 8 16 32 64 128 256 +336 130 -90 0 8 1 9 1 2 4 8 16 32 64 128 256 +337 80 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +338 80 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +339 80 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +340 110 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +341 110 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +342 140 -140 0 4 1 9 1 2 4 8 16 32 64 128 256 +343 140 -110 0 4 1 9 1 2 4 8 16 32 64 128 256 +344 140 -80 0 4 1 9 1 2 4 8 16 32 64 128 256 +345 70 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +346 70 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +347 70 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +348 110 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +349 110 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +350 150 -150 0 2 1 9 1 2 4 8 16 32 64 128 256 +351 150 -110 0 2 1 9 1 2 4 8 16 32 64 128 256 +352 150 -70 0 2 1 9 1 2 4 8 16 32 64 128 256 +353 60 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +354 60 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +355 60 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +356 110 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +357 110 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +358 160 -160 0 1 1 9 1 2 4 8 16 32 64 128 256 +359 160 -110 0 1 1 9 1 2 4 8 16 32 64 128 256 +360 160 -60 0 1 1 9 1 2 4 8 16 32 64 128 256 +361 0 0 0 0 0 0 +362 110 0 0 0 0 0 +363 110 110 0 0 0 0 +364 0 110 0 0 0 0 +365 -110 110 0 0 0 0 +366 -110 0 0 0 0 0 +367 -110 -110 0 0 0 0 +368 0 -110 0 0 0 0 +369 110 -110 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/p23.res b/jsprit-instances/instances/cordeau/p23.res new file mode 100644 index 00000000..deeeebd1 --- /dev/null +++ b/jsprit-instances/instances/cordeau/p23.res @@ -0,0 +1,37 @@ +6095.46 +1 1 174.56 54 0 8 16 24 32 40 158 29 21 13 5 0 +1 2 170.71 54 0 3 11 19 27 35 34 26 18 10 2 0 +1 3 161.29 54 0 1 9 17 25 317 36 28 20 12 4 0 +1 4 174.56 54 0 6 14 22 30 38 73 31 23 15 7 0 +2 1 161.29 54 0 41 49 57 65 39 74 66 58 50 42 0 +2 2 161.29 54 0 46 54 62 70 357 76 68 60 52 44 0 +2 3 170.71 54 0 48 56 64 72 80 79 71 63 55 47 0 +2 4 174.56 54 0 43 51 59 67 75 113 69 61 53 45 0 +3 1 170.71 54 0 88 96 104 112 120 117 109 101 93 85 0 +3 2 174.56 54 0 83 91 99 107 115 160 106 98 90 82 0 +3 3 161.29 54 0 81 89 97 105 77 116 108 100 92 84 0 +3 4 170.71 54 0 86 94 102 110 118 119 111 103 95 87 0 +4 1 161.29 54 0 126 134 142 150 37 156 148 140 132 124 0 +4 2 161.29 54 0 128 136 144 152 114 159 151 143 135 127 0 +4 3 170.71 54 0 123 131 139 147 155 157 149 141 133 125 0 +4 4 170.71 54 0 121 129 137 145 153 154 146 138 130 122 0 +5 1 161.29 54 0 166 174 182 190 237 196 188 180 172 164 0 +5 2 170.71 54 0 168 176 184 192 200 199 191 183 175 167 0 +5 3 170.71 54 0 163 171 179 187 195 197 189 181 173 165 0 +5 4 170.71 54 0 161 169 177 185 193 194 186 178 170 162 0 +6 1 170.71 54 0 206 214 222 230 238 239 231 223 215 207 0 +6 2 174.56 54 0 208 216 224 232 240 198 229 221 213 205 0 +6 3 170.71 54 0 203 211 219 227 235 234 226 218 210 202 0 +6 4 170.71 54 0 201 209 217 225 233 236 228 220 212 204 0 +7 1 174.56 54 0 246 254 262 270 278 313 271 263 255 247 0 +7 2 170.71 54 0 248 256 264 272 280 277 269 261 253 245 0 +7 3 170.71 54 0 243 251 259 267 275 274 266 258 250 242 0 +7 4 170.71 54 0 241 249 257 265 273 276 268 260 252 244 0 +8 1 161.29 54 0 281 289 297 305 279 314 306 298 290 282 0 +8 2 170.71 54 0 286 294 302 310 318 316 308 300 292 284 0 +8 3 161.29 54 0 288 296 304 312 354 319 311 303 295 287 0 +8 4 174.56 54 0 283 291 299 307 315 33 309 301 293 285 0 +9 1 174.56 54 0 323 331 339 347 355 320 346 338 330 322 0 +9 2 170.71 54 0 321 329 337 345 353 356 348 340 332 324 0 +9 3 170.71 54 0 326 334 342 350 358 359 351 343 335 327 0 +9 4 174.56 54 0 328 336 344 352 360 78 349 341 333 325 0 diff --git a/jsprit-instances/instances/cordeau/pr01 b/jsprit-instances/instances/cordeau/pr01 new file mode 100644 index 00000000..1b8c56bf --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr01 @@ -0,0 +1,57 @@ +2 1 48 4 +500 200 +500 200 +500 200 +500 200 + 1 -29.730 64.136 2 12 1 4 1 2 4 8 + 2 -30.664 5.463 7 8 1 4 1 2 4 8 + 3 51.642 5.469 21 16 1 4 1 2 4 8 + 4 -13.171 69.336 24 5 1 4 1 2 4 8 + 5 -67.413 68.323 1 12 1 4 1 2 4 8 + 6 48.907 6.274 17 5 1 4 1 2 4 8 + 7 5.243 22.260 6 13 1 4 1 2 4 8 + 8 -65.002 77.234 5 20 1 4 1 2 4 8 + 9 -4.175 -1.569 7 13 1 4 1 2 4 8 + 10 23.029 11.639 1 18 1 4 1 2 4 8 + 11 25.482 6.287 4 7 1 4 1 2 4 8 + 12 -42.615 -26.392 10 6 1 4 1 2 4 8 + 13 -76.672 99.341 2 9 1 4 1 2 4 8 + 14 -20.673 57.892 16 9 1 4 1 2 4 8 + 15 -52.039 6.567 23 4 1 4 1 2 4 8 + 16 -41.376 50.824 18 25 1 4 1 2 4 8 + 17 -91.943 27.588 3 5 1 4 1 2 4 8 + 18 -65.118 30.212 15 17 1 4 1 2 4 8 + 19 18.597 96.716 13 3 1 4 1 2 4 8 + 20 -40.942 83.209 10 16 1 4 1 2 4 8 + 21 -37.756 -33.325 4 25 1 4 1 2 4 8 + 22 23.767 29.083 23 21 1 4 1 2 4 8 + 23 -43.030 20.453 20 14 1 4 1 2 4 8 + 24 -35.297 -24.896 10 19 1 4 1 2 4 8 + 25 -54.755 14.368 4 14 1 4 1 2 4 8 + 26 -49.329 33.374 2 6 1 4 1 2 4 8 + 27 57.404 23.822 23 16 1 4 1 2 4 8 + 28 -22.754 55.408 6 9 1 4 1 2 4 8 + 29 -56.622 73.340 8 20 1 4 1 2 4 8 + 30 -38.562 -3.705 10 13 1 4 1 2 4 8 + 31 -16.779 19.537 7 10 1 4 1 2 4 8 + 32 -11.560 11.615 1 16 1 4 1 2 4 8 + 33 -46.545 97.974 21 19 1 4 1 2 4 8 + 34 16.229 9.320 6 22 1 4 1 2 4 8 + 35 1.294 7.349 4 14 1 4 1 2 4 8 + 36 -26.404 29.529 13 10 1 4 1 2 4 8 + 37 4.352 14.685 9 11 1 4 1 2 4 8 + 38 -50.665 -23.126 22 15 1 4 1 2 4 8 + 39 -22.833 -9.814 22 13 1 4 1 2 4 8 + 40 -71.100 -18.616 18 15 1 4 1 2 4 8 + 41 -7.849 32.074 10 8 1 4 1 2 4 8 + 42 11.877 -24.933 25 22 1 4 1 2 4 8 + 43 -18.927 -23.730 23 24 1 4 1 2 4 8 + 44 -11.920 11.755 4 3 1 4 1 2 4 8 + 45 29.840 11.633 9 25 1 4 1 2 4 8 + 46 12.268 -55.811 17 19 1 4 1 2 4 8 + 47 -37.933 -21.613 10 21 1 4 1 2 4 8 + 48 42.883 -2.966 17 10 1 4 1 2 4 8 + 49 4.163 13.559 0 0 0 0 + 50 21.387 17.105 0 0 0 0 + 51 -36.118 49.097 0 0 0 0 + 52 -31.201 0.235 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr01.res b/jsprit-instances/instances/cordeau/pr01.res new file mode 100644 index 00000000..cb71726e --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr01.res @@ -0,0 +1,5 @@ +861.32 +1 1 375.24 176.00 49 37 7 41 36 31 44 32 39 43 46 42 9 35 49 +2 1 249.26 140.00 50 22 27 3 6 48 45 11 10 34 50 +3 1 398.23 159.00 51 1 28 14 4 19 20 33 13 8 5 29 16 51 +4 1 391.59 182.00 52 2 15 25 23 26 18 17 40 38 12 21 24 47 30 52 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr02 b/jsprit-instances/instances/cordeau/pr02 new file mode 100644 index 00000000..0e397ef2 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr02 @@ -0,0 +1,105 @@ +2 2 96 4 +480 195 +480 195 +480 195 +480 195 + 1 33.588 30.750 12 4 1 4 1 2 4 8 + 2 48.828 65.314 1 12 1 4 1 2 4 8 + 3 86.176 59.344 1 3 1 4 1 2 4 8 + 4 39.270 -33.057 15 15 1 4 1 2 4 8 + 5 -23.370 86.853 10 13 1 4 1 2 4 8 + 6 48.132 95.593 12 20 1 4 1 2 4 8 + 7 -16.357 93.311 15 21 1 4 1 2 4 8 + 8 -57.703 -65.601 16 4 1 4 1 2 4 8 + 9 7.147 32.684 18 25 1 4 1 2 4 8 + 10 42.950 68.701 9 21 1 4 1 2 4 8 + 11 37.085 -2.112 5 7 1 4 1 2 4 8 + 12 77.759 55.817 19 3 1 4 1 2 4 8 + 13 -17.462 -56.567 11 9 1 4 1 2 4 8 + 14 58.575 59.888 12 5 1 4 1 2 4 8 + 15 57.776 15.344 13 20 1 4 1 2 4 8 + 16 -22.327 36.072 8 21 1 4 1 2 4 8 + 17 -7.080 30.493 14 19 1 4 1 2 4 8 + 18 55.658 60.425 9 2 1 4 1 2 4 8 + 19 -14.307 11.456 2 16 1 4 1 2 4 8 + 20 -29.724 24.268 25 18 1 4 1 2 4 8 + 21 43.219 0.739 6 24 1 4 1 2 4 8 + 22 45.184 35.474 16 24 1 4 1 2 4 8 + 23 64.484 2.240 18 8 1 4 1 2 4 8 + 24 55.078 72.241 4 16 1 4 1 2 4 8 + 25 16.925 15.741 17 19 1 4 1 2 4 8 + 26 45.038 -3.723 4 12 1 4 1 2 4 8 + 27 -76.782 5.939 22 9 1 4 1 2 4 8 + 28 36.169 0.256 12 3 1 4 1 2 4 8 + 29 29.218 8.936 13 15 1 4 1 2 4 8 + 30 65.057 5.225 5 4 1 4 1 2 4 8 + 31 42.175 -22.284 24 24 1 4 1 2 4 8 + 32 25.574 31.726 12 22 1 4 1 2 4 8 + 33 31.561 37.262 16 14 1 4 1 2 4 8 + 34 66.498 -54.169 8 11 1 4 1 2 4 8 + 35 46.576 -17.938 10 20 1 4 1 2 4 8 + 36 65.063 40.875 15 5 1 4 1 2 4 8 + 37 -2.716 24.768 21 11 1 4 1 2 4 8 + 38 -40.002 3.870 5 12 1 4 1 2 4 8 + 39 -73.505 57.043 9 7 1 4 1 2 4 8 + 40 81.146 -25.714 5 1 1 4 1 2 4 8 + 41 12.006 -7.965 9 23 1 4 1 2 4 8 + 42 42.761 38.092 20 13 1 4 1 2 4 8 + 43 3.857 -23.181 14 4 1 4 1 2 4 8 + 44 -7.367 24.390 24 23 1 4 1 2 4 8 + 45 35.944 -11.835 23 17 1 4 1 2 4 8 + 46 52.075 9.692 12 13 1 4 1 2 4 8 + 47 30.725 30.701 13 9 1 4 1 2 4 8 + 48 41.223 77.924 19 10 1 4 1 2 4 8 + 49 68.884 -40.546 21 22 1 4 1 2 4 8 + 50 76.312 86.670 5 21 1 4 1 2 4 8 + 51 63.934 78.540 9 13 1 4 1 2 4 8 + 52 29.150 -9.961 23 25 1 4 1 2 4 8 + 53 85.522 39.954 8 8 1 4 1 2 4 8 + 54 31.775 3.870 5 20 1 4 1 2 4 8 + 55 -20.544 19.086 8 3 1 4 1 2 4 8 + 56 55.353 43.817 10 4 1 4 1 2 4 8 + 57 35.406 10.278 9 13 1 4 1 2 4 8 + 58 25.464 -0.287 21 18 1 4 1 2 4 8 + 59 12.396 0.244 12 1 1 4 1 2 4 8 + 60 18.359 20.917 8 10 1 4 1 2 4 8 + 61 27.960 -15.039 4 16 1 4 1 2 4 8 + 62 -3.192 19.879 14 9 1 4 1 2 4 8 + 63 9.332 -41.351 19 13 1 4 1 2 4 8 + 64 -20.581 38.177 23 23 1 4 1 2 4 8 + 65 27.820 28.729 4 14 1 4 1 2 4 8 + 66 59.027 42.310 9 5 1 4 1 2 4 8 + 67 56.311 58.734 1 1 1 4 1 2 4 8 + 68 -51.654 -0.342 21 6 1 4 1 2 4 8 + 69 2.576 32.721 20 20 1 4 1 2 4 8 + 70 15.131 -3.046 24 10 1 4 1 2 4 8 + 71 66.595 34.937 22 19 1 4 1 2 4 8 + 72 19.476 20.142 25 24 1 4 1 2 4 8 + 73 -1.172 20.648 19 3 1 4 1 2 4 8 + 74 -21.204 13.660 14 5 1 4 1 2 4 8 + 75 98.846 1.257 11 13 1 4 1 2 4 8 + 76 82.593 72.003 22 5 1 4 1 2 4 8 + 77 30.017 -30.896 25 4 1 4 1 2 4 8 + 78 33.228 41.663 5 12 1 4 1 2 4 8 + 79 39.490 -8.539 10 11 1 4 1 2 4 8 + 80 54.498 70.813 4 20 1 4 1 2 4 8 + 81 3.058 10.248 4 13 1 4 1 2 4 8 + 82 51.831 -16.870 6 1 1 4 1 2 4 8 + 83 76.416 11.346 22 3 1 4 1 2 4 8 + 84 5.243 0.238 17 2 1 4 1 2 4 8 + 85 50.592 34.247 22 23 1 4 1 2 4 8 + 86 -5.231 -2.081 3 8 1 4 1 2 4 8 + 87 24.194 25.836 25 25 1 4 1 2 4 8 + 88 33.630 37.585 22 18 1 4 1 2 4 8 + 89 31.445 -7.001 23 4 1 4 1 2 4 8 + 90 30.707 -28.168 16 5 1 4 1 2 4 8 + 91 49.860 1.038 13 21 1 4 1 2 4 8 + 92 -35.767 14.142 23 23 1 4 1 2 4 8 + 93 -29.309 4.889 1 19 1 4 1 2 4 8 + 94 19.049 41.974 11 2 1 4 1 2 4 8 + 95 27.600 13.934 19 21 1 4 1 2 4 8 + 96 52.832 50.684 21 10 1 4 1 2 4 8 + 97 6.229 10.590 0 0 0 0 + 98 32.663 44.730 0 0 0 0 + 99 48.807 48.792 0 0 0 0 +100 33.179 -4.968 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr02.res b/jsprit-instances/instances/cordeau/pr02.res new file mode 100644 index 00000000..08c33840 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr02.res @@ -0,0 +1,9 @@ +1307.61 +1 1 479.98 164.00 97 81 86 19 74 93 92 38 68 27 8 13 63 43 41 97 +1 2 341.16 176.00 97 73 62 37 25 60 72 95 29 57 54 58 70 59 84 97 +2 1 469.05 195.00 98 7 5 39 64 16 20 55 44 17 69 9 94 98 +2 2 240.08 178.00 98 78 88 33 32 87 65 47 1 85 22 42 98 +3 1 403.44 193.00 99 56 66 36 71 53 12 3 76 50 51 6 48 10 2 80 24 18 14 67 99 +3 2 29.90 10.00 99 96 99 +4 1 408.91 194.00 100 79 35 82 34 49 40 75 83 23 30 15 46 91 26 21 28 11 100 +4 2 221.09 110.00 100 89 52 61 90 77 4 31 45 100 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr03 b/jsprit-instances/instances/cordeau/pr03 new file mode 100644 index 00000000..fe337dcb --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr03 @@ -0,0 +1,153 @@ +2 3 144 4 +460 190 +460 190 +460 190 +460 190 + 1 -55.280 -24.371 25 9 1 4 1 2 4 8 + 2 -48.297 53.314 13 22 1 4 1 2 4 8 + 3 -49.072 -38.489 20 10 1 4 1 2 4 8 + 4 25.311 -18.561 16 24 1 4 1 2 4 8 + 5 -24.469 -3.815 4 25 1 4 1 2 4 8 + 6 24.591 -17.896 2 6 1 4 1 2 4 8 + 7 -10.419 60.364 7 22 1 4 1 2 4 8 + 8 38.177 -35.175 15 1 1 4 1 2 4 8 + 9 -68.280 93.073 10 19 1 4 1 2 4 8 + 10 -30.792 -57.336 4 19 1 4 1 2 4 8 + 11 -37.061 -12.122 19 5 1 4 1 2 4 8 + 12 -15.741 -47.638 10 9 1 4 1 2 4 8 + 13 -63.379 -22.919 15 8 1 4 1 2 4 8 + 14 -43.109 -43.439 4 14 1 4 1 2 4 8 + 15 -25.623 13.599 17 4 1 4 1 2 4 8 + 16 -2.625 16.632 4 7 1 4 1 2 4 8 + 17 -41.577 -28.497 3 10 1 4 1 2 4 8 + 18 2.081 12.885 9 22 1 4 1 2 4 8 + 19 3.925 -47.845 25 17 1 4 1 2 4 8 + 20 -83.295 26.324 14 10 1 4 1 2 4 8 + 21 -6.458 26.355 23 8 1 4 1 2 4 8 + 22 3.290 6.732 7 14 1 4 1 2 4 8 + 23 -34.869 30.426 7 12 1 4 1 2 4 8 + 24 15.546 -36.273 1 17 1 4 1 2 4 8 + 25 12.842 5.127 10 19 1 4 1 2 4 8 + 26 -48.450 -24.426 15 25 1 4 1 2 4 8 + 27 -88.538 -10.461 1 25 1 4 1 2 4 8 + 28 -29.773 0.995 2 6 1 4 1 2 4 8 + 29 9.827 38.416 9 21 1 4 1 2 4 8 + 30 1.410 92.938 10 3 1 4 1 2 4 8 + 31 -79.303 15.381 2 19 1 4 1 2 4 8 + 32 -30.652 40.063 23 16 1 4 1 2 4 8 + 33 18.927 21.637 15 21 1 4 1 2 4 8 + 34 45.087 -59.906 13 17 1 4 1 2 4 8 + 35 -34.949 -3.815 16 19 1 4 1 2 4 8 + 36 81.201 -74.744 21 6 1 4 1 2 4 8 + 37 15.594 -28.455 1 10 1 4 1 2 4 8 + 38 -72.192 29.547 18 22 1 4 1 2 4 8 + 39 -42.914 -22.675 17 17 1 4 1 2 4 8 + 40 -76.392 -57.489 13 16 1 4 1 2 4 8 + 41 -28.540 12.073 5 5 1 4 1 2 4 8 + 42 -61.389 26.526 23 1 1 4 1 2 4 8 + 43 -8.472 12.616 20 21 1 4 1 2 4 8 + 44 -61.475 33.392 1 20 1 4 1 2 4 8 + 45 -34.674 -27.588 2 6 1 4 1 2 4 8 + 46 10.315 -12.518 15 1 1 4 1 2 4 8 + 47 -83.014 77.002 20 11 1 4 1 2 4 8 + 48 -40.417 49.988 9 22 1 4 1 2 4 8 + 49 83.832 33.905 13 25 1 4 1 2 4 8 + 50 -20.563 -75.830 4 18 1 4 1 2 4 8 + 51 15.442 -18.719 15 9 1 4 1 2 4 8 + 52 -59.937 -65.802 5 23 1 4 1 2 4 8 + 53 5.151 47.815 8 17 1 4 1 2 4 8 + 54 46.008 14.990 19 4 1 4 1 2 4 8 + 55 82.977 -1.660 16 1 1 4 1 2 4 8 + 56 39.893 -38.916 11 14 1 4 1 2 4 8 + 57 90.839 -83.539 23 11 1 4 1 2 4 8 + 58 7.068 0.067 14 7 1 4 1 2 4 8 + 59 18.958 40.088 24 21 1 4 1 2 4 8 + 60 -80.487 58.209 5 3 1 4 1 2 4 8 + 61 64.459 -62.946 5 18 1 4 1 2 4 8 + 62 -43.616 -26.117 23 5 1 4 1 2 4 8 + 63 -18.408 10.303 3 6 1 4 1 2 4 8 + 64 -43.921 63.251 10 22 1 4 1 2 4 8 + 65 11.353 26.221 23 13 1 4 1 2 4 8 + 66 -6.995 38.239 23 17 1 4 1 2 4 8 + 67 74.084 -34.216 20 5 1 4 1 2 4 8 + 68 14.301 -0.800 5 7 1 4 1 2 4 8 + 69 -94.141 -48.779 14 1 1 4 1 2 4 8 + 70 15.332 -42.169 1 3 1 4 1 2 4 8 + 71 -46.637 -16.461 10 10 1 4 1 2 4 8 + 72 -0.958 -81.000 3 5 1 4 1 2 4 8 + 73 -37.445 -42.505 4 1 1 4 1 2 4 8 + 74 -3.680 -69.073 23 17 1 4 1 2 4 8 + 75 34.894 -20.898 21 14 1 4 1 2 4 8 + 76 45.544 51.410 3 4 1 4 1 2 4 8 + 77 -31.927 88.239 21 10 1 4 1 2 4 8 + 78 -13.580 -26.959 25 25 1 4 1 2 4 8 + 79 12.653 -48.340 5 11 1 4 1 2 4 8 + 80 -46.179 -38.269 11 16 1 4 1 2 4 8 + 81 -29.620 35.083 10 25 1 4 1 2 4 8 + 82 13.696 43.988 5 20 1 4 1 2 4 8 + 83 38.342 -46.338 3 3 1 4 1 2 4 8 + 84 -26.227 24.506 13 7 1 4 1 2 4 8 + 85 90.009 -43.640 19 2 1 4 1 2 4 8 + 86 -6.995 22.522 13 6 1 4 1 2 4 8 + 87 -29.993 -28.851 8 14 1 4 1 2 4 8 + 88 -56.268 -64.740 13 14 1 4 1 2 4 8 + 89 -87.415 90.796 15 2 1 4 1 2 4 8 + 90 -5.762 54.034 10 15 1 4 1 2 4 8 + 91 -34.845 -27.185 4 22 1 4 1 2 4 8 + 92 -16.479 16.180 23 4 1 4 1 2 4 8 + 93 23.712 29.492 23 22 1 4 1 2 4 8 + 94 -40.991 46.594 14 19 1 4 1 2 4 8 + 95 -53.516 -21.619 20 5 1 4 1 2 4 8 + 96 -17.560 37.494 3 10 1 4 1 2 4 8 + 97 -37.311 56.836 5 4 1 4 1 2 4 8 + 98 71.515 22.510 16 7 1 4 1 2 4 8 + 99 -41.864 27.710 21 11 1 4 1 2 4 8 +100 14.819 -82.117 4 14 1 4 1 2 4 8 +101 30.316 -55.322 2 2 1 4 1 2 4 8 +102 -39.172 47.998 11 12 1 4 1 2 4 8 +103 -94.415 15.192 15 12 1 4 1 2 4 8 +104 -7.806 11.273 16 24 1 4 1 2 4 8 +105 28.571 -49.908 3 8 1 4 1 2 4 8 +106 -20.654 24.554 21 4 1 4 1 2 4 8 +107 -30.963 -18.903 21 25 1 4 1 2 4 8 +108 1.721 -20.447 25 6 1 4 1 2 4 8 +109 -31.012 -21.106 12 9 1 4 1 2 4 8 +110 -85.718 -28.015 21 23 1 4 1 2 4 8 +111 58.826 -63.043 6 15 1 4 1 2 4 8 +112 -15.753 -52.686 2 7 1 4 1 2 4 8 +113 -71.661 51.184 24 6 1 4 1 2 4 8 +114 -92.633 -6.598 21 5 1 4 1 2 4 8 +115 33.508 -49.255 24 12 1 4 1 2 4 8 +116 59.314 54.095 11 3 1 4 1 2 4 8 +117 30.737 -28.436 12 22 1 4 1 2 4 8 +118 -55.896 18.457 22 18 1 4 1 2 4 8 +119 -89.960 -39.532 19 16 1 4 1 2 4 8 +120 36.438 20.819 8 5 1 4 1 2 4 8 +121 -53.674 -56.427 9 1 1 4 1 2 4 8 +122 -31.866 32.538 10 8 1 4 1 2 4 8 +123 5.658 12.756 5 20 1 4 1 2 4 8 +124 -52.905 42.804 14 17 1 4 1 2 4 8 +125 47.131 -45.465 7 11 1 4 1 2 4 8 +126 30.792 9.869 5 8 1 4 1 2 4 8 +127 -45.209 -56.293 22 15 1 4 1 2 4 8 +128 10.919 13.306 5 16 1 4 1 2 4 8 +129 -32.990 -34.003 1 6 1 4 1 2 4 8 +130 -40.869 30.579 9 24 1 4 1 2 4 8 +131 -69.348 80.408 16 10 1 4 1 2 4 8 +132 -58.966 -29.541 14 4 1 4 1 2 4 8 +133 -36.847 -33.710 21 10 1 4 1 2 4 8 +134 -21.820 65.369 8 17 1 4 1 2 4 8 +135 22.980 -41.010 7 5 1 4 1 2 4 8 +136 -77.557 59.814 24 14 1 4 1 2 4 8 +137 -47.205 67.725 24 16 1 4 1 2 4 8 +138 -21.606 35.168 16 11 1 4 1 2 4 8 +139 -55.676 -31.384 4 25 1 4 1 2 4 8 +140 -85.229 88.788 7 4 1 4 1 2 4 8 +141 -3.918 -63.525 13 12 1 4 1 2 4 8 +142 -58.557 59.375 25 19 1 4 1 2 4 8 +143 -24.542 14.935 10 6 1 4 1 2 4 8 +144 -48.779 16.968 24 23 1 4 1 2 4 8 +145 -40.082 -24.780 0 0 0 0 +146 24.292 -27.704 0 0 0 0 +147 -45.877 41.092 0 0 0 0 +148 -11.896 15.875 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr03.res b/jsprit-instances/instances/cordeau/pr03.res new file mode 100644 index 00000000..991f7269 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr03.res @@ -0,0 +1,13 @@ +1806.60 +1 1 406.31 183.00 145 95 13 27 114 110 119 69 40 52 88 121 127 14 73 129 133 145 +1 2 168.26 104.00 145 62 26 1 132 139 3 80 17 145 +1 3 196.57 158.00 145 91 45 87 109 107 5 28 35 11 71 39 145 +2 1 445.26 144.00 146 4 6 126 54 120 33 93 76 116 49 98 55 75 146 +2 2 402.12 190.00 146 24 70 79 19 141 74 100 72 50 10 112 12 78 108 46 51 146 +2 3 430.42 162.00 146 117 8 56 125 67 85 57 36 61 111 34 83 115 101 105 135 37 146 +3 1 236.54 138.00 147 32 81 122 23 130 99 144 118 42 147 +3 2 327.19 184.00 147 2 64 137 77 30 90 7 134 97 48 102 94 147 +3 3 440.90 188.00 147 44 38 31 103 20 113 60 136 47 140 89 9 131 142 124 147 +4 1 -0.00 0.00 148 148 +4 2 389.17 180.00 148 92 63 41 15 143 84 106 138 96 66 53 82 59 29 65 21 86 148 +4 3 166.85 157.00 148 43 104 22 58 68 25 128 123 18 16 148 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr04 b/jsprit-instances/instances/cordeau/pr04 new file mode 100644 index 00000000..ce58d961 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr04 @@ -0,0 +1,201 @@ +2 4 192 4 +440 185 +440 185 +440 185 +440 185 + 1 -44.629 -55.640 6 11 1 4 1 2 4 8 + 2 36.096 64.935 16 11 1 4 1 2 4 8 + 3 -25.470 44.580 7 23 1 4 1 2 4 8 + 4 -33.954 -73.059 20 16 1 4 1 2 4 8 + 5 45.654 35.730 7 16 1 4 1 2 4 8 + 6 14.954 -36.719 8 2 1 4 1 2 4 8 + 7 -1.477 47.205 4 1 1 4 1 2 4 8 + 8 2.155 -40.912 23 25 1 4 1 2 4 8 + 9 22.992 1.398 4 24 1 4 1 2 4 8 + 10 -28.857 5.957 5 14 1 4 1 2 4 8 + 11 -48.120 94.116 15 6 1 4 1 2 4 8 + 12 7.239 17.322 12 20 1 4 1 2 4 8 + 13 4.614 27.051 12 10 1 4 1 2 4 8 + 14 -13.971 28.198 18 11 1 4 1 2 4 8 + 15 12.946 -11.688 19 2 1 4 1 2 4 8 + 16 -36.670 23.102 17 22 1 4 1 2 4 8 + 17 -4.224 -49.310 2 2 1 4 1 2 4 8 + 18 1.093 -7.135 15 12 1 4 1 2 4 8 + 19 -56.958 27.905 10 9 1 4 1 2 4 8 + 20 -80.994 -77.686 3 21 1 4 1 2 4 8 + 21 72.260 59.027 24 10 1 4 1 2 4 8 + 22 -21.655 1.636 1 13 1 4 1 2 4 8 + 23 -20.154 -62.415 22 25 1 4 1 2 4 8 + 24 -48.157 6.287 22 9 1 4 1 2 4 8 + 25 -5.078 61.597 17 19 1 4 1 2 4 8 + 26 17.145 -47.046 7 22 1 4 1 2 4 8 + 27 -16.064 8.557 11 4 1 4 1 2 4 8 + 28 6.683 -27.069 4 4 1 4 1 2 4 8 + 29 15.027 -34.979 15 7 1 4 1 2 4 8 + 30 37.946 73.914 15 20 1 4 1 2 4 8 + 31 -41.199 -43.018 9 17 1 4 1 2 4 8 + 32 32.538 11.786 15 19 1 4 1 2 4 8 + 33 -20.306 -20.239 1 12 1 4 1 2 4 8 + 34 -35.480 19.135 13 2 1 4 1 2 4 8 + 35 58.038 56.659 17 13 1 4 1 2 4 8 + 36 -36.694 -6.256 17 24 1 4 1 2 4 8 + 37 0.446 -46.735 25 22 1 4 1 2 4 8 + 38 -19.690 38.977 5 17 1 4 1 2 4 8 + 39 -47.339 20.911 25 19 1 4 1 2 4 8 + 40 -79.236 -57.678 2 4 1 4 1 2 4 8 + 41 5.597 -34.076 9 12 1 4 1 2 4 8 + 42 34.454 -8.289 7 22 1 4 1 2 4 8 + 43 18.500 -51.154 5 2 1 4 1 2 4 8 + 44 -4.346 -44.525 3 19 1 4 1 2 4 8 + 45 -14.148 -74.164 17 3 1 4 1 2 4 8 + 46 19.867 77.515 12 5 1 4 1 2 4 8 + 47 -50.079 17.871 21 22 1 4 1 2 4 8 + 48 42.786 -79.883 18 6 1 4 1 2 4 8 + 49 1.520 -29.034 8 9 1 4 1 2 4 8 + 50 14.728 -3.436 14 8 1 4 1 2 4 8 + 51 -26.166 -48.999 22 24 1 4 1 2 4 8 + 52 -63.873 -5.273 16 15 1 4 1 2 4 8 + 53 -54.138 7.086 21 16 1 4 1 2 4 8 + 54 17.932 -34.094 7 9 1 4 1 2 4 8 + 55 -98.706 34.552 12 1 1 4 1 2 4 8 + 56 28.802 -8.582 2 18 1 4 1 2 4 8 + 57 2.716 90.594 5 17 1 4 1 2 4 8 + 58 -31.024 48.938 3 18 1 4 1 2 4 8 + 59 -46.545 42.316 11 2 1 4 1 2 4 8 + 60 27.289 58.179 2 25 1 4 1 2 4 8 + 61 28.815 -28.027 7 21 1 4 1 2 4 8 + 62 -26.099 11.328 20 19 1 4 1 2 4 8 + 63 0.537 -26.221 7 10 1 4 1 2 4 8 + 64 -50.458 7.812 11 2 1 4 1 2 4 8 + 65 30.005 19.092 24 21 1 4 1 2 4 8 + 66 -12.604 22.058 15 20 1 4 1 2 4 8 + 67 22.009 -8.636 5 21 1 4 1 2 4 8 + 68 8.942 2.875 25 2 1 4 1 2 4 8 + 69 -19.812 0.922 12 6 1 4 1 2 4 8 + 70 -4.230 31.250 22 2 1 4 1 2 4 8 + 71 17.975 -0.409 11 12 1 4 1 2 4 8 + 72 -2.350 42.938 16 12 1 4 1 2 4 8 + 73 -16.516 68.085 10 5 1 4 1 2 4 8 + 74 -1.190 42.023 3 5 1 4 1 2 4 8 + 75 56.635 -44.019 10 8 1 4 1 2 4 8 + 76 57.483 35.504 17 15 1 4 1 2 4 8 + 77 -26.099 7.477 2 8 1 4 1 2 4 8 + 78 7.489 -57.239 21 7 1 4 1 2 4 8 + 79 -22.095 55.780 16 14 1 4 1 2 4 8 + 80 19.867 38.824 6 18 1 4 1 2 4 8 + 81 5.310 49.219 12 17 1 4 1 2 4 8 + 82 15.155 6.299 23 5 1 4 1 2 4 8 + 83 5.481 -31.500 23 6 1 4 1 2 4 8 + 84 7.959 -28.662 18 9 1 4 1 2 4 8 + 85 -75.812 4.010 18 24 1 4 1 2 4 8 + 86 -43.671 -61.646 14 13 1 4 1 2 4 8 + 87 -2.576 -62.140 2 5 1 4 1 2 4 8 + 88 -18.842 -36.884 11 4 1 4 1 2 4 8 + 89 20.844 21.167 24 22 1 4 1 2 4 8 + 90 3.137 -19.220 14 24 1 4 1 2 4 8 + 91 -20.361 18.878 3 25 1 4 1 2 4 8 + 92 -0.897 -54.938 21 9 1 4 1 2 4 8 + 93 -29.553 9.277 8 8 1 4 1 2 4 8 + 94 5.048 -35.046 19 8 1 4 1 2 4 8 + 95 27.759 48.712 7 25 1 4 1 2 4 8 + 96 12.079 -42.346 19 7 1 4 1 2 4 8 + 97 -51.270 41.144 23 24 1 4 1 2 4 8 + 98 -29.077 4.291 8 16 1 4 1 2 4 8 + 99 -18.555 -14.819 18 15 1 4 1 2 4 8 +100 7.855 -49.451 7 7 1 4 1 2 4 8 +101 -19.116 -32.086 1 17 1 4 1 2 4 8 +102 17.651 -52.271 9 9 1 4 1 2 4 8 +103 16.907 -62.964 5 14 1 4 1 2 4 8 +104 18.988 6.219 23 20 1 4 1 2 4 8 +105 -68.878 -64.539 18 6 1 4 1 2 4 8 +106 -13.361 20.264 5 17 1 4 1 2 4 8 +107 -44.440 63.721 17 23 1 4 1 2 4 8 +108 -6.500 71.436 9 14 1 4 1 2 4 8 +109 -51.978 25.409 19 19 1 4 1 2 4 8 +110 -0.739 59.491 20 21 1 4 1 2 4 8 +111 -64.679 83.038 1 6 1 4 1 2 4 8 +112 -11.273 -35.944 18 1 1 4 1 2 4 8 +113 -16.864 7.776 15 22 1 4 1 2 4 8 +114 19.843 -49.805 10 7 1 4 1 2 4 8 +115 -16.284 -2.936 8 14 1 4 1 2 4 8 +116 8.356 67.041 14 7 1 4 1 2 4 8 +117 30.878 24.316 15 25 1 4 1 2 4 8 +118 93.524 -20.233 17 17 1 4 1 2 4 8 +119 -9.332 -56.177 9 10 1 4 1 2 4 8 +120 -34.442 -63.312 13 23 1 4 1 2 4 8 +121 20.941 -5.646 18 22 1 4 1 2 4 8 +122 -3.418 89.594 20 3 1 4 1 2 4 8 +123 -18.738 45.227 8 14 1 4 1 2 4 8 +124 2.435 -30.524 2 14 1 4 1 2 4 8 +125 -28.864 56.616 7 2 1 4 1 2 4 8 +126 76.880 -29.901 6 2 1 4 1 2 4 8 +127 -90.466 10.278 12 21 1 4 1 2 4 8 +128 -35.101 46.545 12 10 1 4 1 2 4 8 +129 -48.395 43.854 25 10 1 4 1 2 4 8 +130 -40.997 26.703 6 5 1 4 1 2 4 8 +131 13.696 34.607 5 9 1 4 1 2 4 8 +132 -71.472 11.450 20 15 1 4 1 2 4 8 +133 -36.230 51.904 2 19 1 4 1 2 4 8 +134 -39.465 4.907 25 7 1 4 1 2 4 8 +135 -16.565 23.773 7 11 1 4 1 2 4 8 +136 10.754 -28.552 6 2 1 4 1 2 4 8 +137 -23.029 47.015 21 25 1 4 1 2 4 8 +138 -8.807 21.216 19 14 1 4 1 2 4 8 +139 -40.039 27.435 22 15 1 4 1 2 4 8 +140 -37.445 -41.040 8 12 1 4 1 2 4 8 +141 48.224 0.085 19 11 1 4 1 2 4 8 +142 -0.323 68.237 6 17 1 4 1 2 4 8 +143 -14.294 -33.423 24 4 1 4 1 2 4 8 +144 -1.440 -34.814 15 24 1 4 1 2 4 8 +145 -34.454 42.346 25 8 1 4 1 2 4 8 +146 8.679 -66.180 6 20 1 4 1 2 4 8 +147 -61.249 -51.367 21 12 1 4 1 2 4 8 +148 -1.093 9.912 4 10 1 4 1 2 4 8 +149 -16.565 66.547 10 12 1 4 1 2 4 8 +150 8.435 52.838 16 9 1 4 1 2 4 8 +151 -22.034 -36.896 12 16 1 4 1 2 4 8 +152 15.765 17.322 13 23 1 4 1 2 4 8 +153 9.003 -18.695 2 15 1 4 1 2 4 8 +154 -4.584 3.491 3 10 1 4 1 2 4 8 +155 8.875 40.662 10 21 1 4 1 2 4 8 +156 26.093 -33.966 18 2 1 4 1 2 4 8 +157 -32.501 39.526 18 16 1 4 1 2 4 8 +158 -32.629 -82.581 11 15 1 4 1 2 4 8 +159 -98.486 22.021 7 11 1 4 1 2 4 8 +160 -59.052 4.163 18 11 1 4 1 2 4 8 +161 7.428 -2.570 15 17 1 4 1 2 4 8 +162 -59.601 12.469 5 3 1 4 1 2 4 8 +163 -11.224 -31.830 20 9 1 4 1 2 4 8 +164 -16.809 -35.040 9 1 1 4 1 2 4 8 +165 21.863 18.140 22 13 1 4 1 2 4 8 +166 45.038 -61.316 13 1 1 4 1 2 4 8 +167 -48.816 25.568 24 2 1 4 1 2 4 8 +168 -32.184 -16.736 4 22 1 4 1 2 4 8 +169 12.439 -41.492 16 10 1 4 1 2 4 8 +170 -21.082 -77.075 16 4 1 4 1 2 4 8 +171 -17.822 -18.518 14 9 1 4 1 2 4 8 +172 48.334 93.518 14 11 1 4 1 2 4 8 +173 -18.677 49.005 25 3 1 4 1 2 4 8 +174 12.140 30.042 23 19 1 4 1 2 4 8 +175 3.113 -40.302 23 19 1 4 1 2 4 8 +176 17.133 37.079 4 4 1 4 1 2 4 8 +177 22.577 0.836 17 19 1 4 1 2 4 8 +178 -30.426 52.942 12 15 1 4 1 2 4 8 +179 33.765 -67.108 11 21 1 4 1 2 4 8 +180 5.414 1.532 24 25 1 4 1 2 4 8 +181 72.156 30.103 22 4 1 4 1 2 4 8 +182 -24.109 -34.625 10 3 1 4 1 2 4 8 +183 17.413 75.146 10 6 1 4 1 2 4 8 +184 10.638 -60.052 10 6 1 4 1 2 4 8 +185 -5.176 -48.999 5 21 1 4 1 2 4 8 +186 -19.342 21.118 13 25 1 4 1 2 4 8 +187 -46.802 -14.661 18 10 1 4 1 2 4 8 +188 -16.779 43.439 25 25 1 4 1 2 4 8 +189 14.093 -13.605 12 19 1 4 1 2 4 8 +190 -21.063 26.019 18 19 1 4 1 2 4 8 +191 39.813 -40.668 9 22 1 4 1 2 4 8 +192 52.057 30.334 23 5 1 4 1 2 4 8 +193 -0.140 7.266 0 0 0 0 +194 -23.138 48.450 0 0 0 0 +195 -26.102 16.809 0 0 0 0 +196 0.244 -35.892 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr04.res b/jsprit-instances/instances/cordeau/pr04.res new file mode 100644 index 00000000..68f2f498 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr04.res @@ -0,0 +1,17 @@ +2072.52 +1 1 245.42 183.00 193 148 12 152 89 65 32 9 177 104 82 193 +1 2 -0.00 0.00 193 193 +1 3 232.84 166.00 193 154 18 90 153 189 15 121 71 50 161 180 193 +1 4 436.49 175.00 193 68 67 56 42 141 192 76 181 21 35 5 117 165 193 +2 1 251.36 179.00 194 3 38 70 13 174 131 176 80 155 74 72 188 123 194 +2 2 376.55 180.00 194 173 7 81 150 95 60 2 30 172 46 183 116 110 25 194 +2 3 348.08 177.00 194 137 79 149 73 108 142 57 122 11 111 107 125 178 58 194 +2 4 -0.00 0.00 194 194 +3 1 358.34 182.00 195 190 157 145 128 133 59 129 97 19 109 167 130 139 16 34 195 +3 2 433.86 184.00 195 39 47 162 132 55 159 127 85 52 160 53 64 24 134 93 195 +3 3 164.42 149.00 195 113 27 106 138 66 14 135 186 91 195 +3 4 236.95 182.00 195 62 77 22 69 115 99 171 33 168 187 36 98 10 195 +4 1 436.71 183.00 196 87 45 170 158 4 120 86 1 105 20 40 147 31 140 182 101 112 196 +4 2 326.18 172.00 196 94 41 83 124 49 63 28 84 136 6 169 96 26 114 43 102 184 78 100 175 196 +4 3 435.93 180.00 196 44 17 92 146 103 179 48 166 75 126 118 191 61 156 54 29 196 +4 4 287.39 185.00 196 8 37 185 119 23 51 151 88 164 143 163 144 196 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr05 b/jsprit-instances/instances/cordeau/pr05 new file mode 100644 index 00000000..9932be50 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr05 @@ -0,0 +1,249 @@ +2 5 240 4 +420 180 +420 180 +420 180 +420 180 + 1 65.991 -49.829 20 10 1 4 1 2 4 8 + 2 -36.938 -36.743 20 25 1 4 1 2 4 8 + 3 -2.734 18.774 13 18 1 4 1 2 4 8 + 4 31.116 -35.907 13 16 1 4 1 2 4 8 + 5 2.789 8.008 17 14 1 4 1 2 4 8 + 6 31.152 43.665 24 7 1 4 1 2 4 8 + 7 -36.304 -21.307 15 9 1 4 1 2 4 8 + 8 52.814 35.046 12 16 1 4 1 2 4 8 + 9 11.267 20.660 20 24 1 4 1 2 4 8 + 10 -0.623 23.114 20 6 1 4 1 2 4 8 + 11 43.091 -12.360 3 22 1 4 1 2 4 8 + 12 6.854 19.073 8 11 1 4 1 2 4 8 + 13 -6.848 25.317 16 19 1 4 1 2 4 8 + 14 -27.930 -23.712 20 20 1 4 1 2 4 8 + 15 33.240 -30.487 21 20 1 4 1 2 4 8 + 16 63.885 -52.881 23 16 1 4 1 2 4 8 + 17 -13.672 -43.945 21 5 1 4 1 2 4 8 + 18 -0.647 -27.502 3 21 1 4 1 2 4 8 + 19 59.406 -49.261 19 19 1 4 1 2 4 8 + 20 27.167 -5.713 20 18 1 4 1 2 4 8 + 21 70.001 -20.844 7 22 1 4 1 2 4 8 + 22 35.327 -65.167 14 19 1 4 1 2 4 8 + 23 -14.386 -42.236 24 15 1 4 1 2 4 8 + 24 19.366 30.273 3 24 1 4 1 2 4 8 + 25 -39.789 10.101 13 20 1 4 1 2 4 8 + 26 -15.753 -40.204 1 17 1 4 1 2 4 8 + 27 -28.418 -40.503 5 20 1 4 1 2 4 8 + 28 27.081 9.735 2 12 1 4 1 2 4 8 + 29 22.205 -9.216 9 23 1 4 1 2 4 8 + 30 -0.830 -6.525 18 15 1 4 1 2 4 8 + 31 10.217 75.531 5 19 1 4 1 2 4 8 + 32 7.446 18.500 12 23 1 4 1 2 4 8 + 33 48.914 -20.294 11 9 1 4 1 2 4 8 + 34 -18.958 -29.675 17 21 1 4 1 2 4 8 + 35 16.815 -6.659 21 17 1 4 1 2 4 8 + 36 2.509 -30.420 5 6 1 4 1 2 4 8 + 37 15.424 4.913 5 10 1 4 1 2 4 8 + 38 60.315 89.801 7 9 1 4 1 2 4 8 + 39 40.405 -45.367 24 19 1 4 1 2 4 8 + 40 -26.837 -54.272 1 17 1 4 1 2 4 8 + 41 69.171 72.577 12 22 1 4 1 2 4 8 + 42 -22.815 46.173 6 8 1 4 1 2 4 8 + 43 -14.258 -30.249 5 25 1 4 1 2 4 8 + 44 76.050 12.073 19 13 1 4 1 2 4 8 + 45 63.043 60.022 23 1 1 4 1 2 4 8 + 46 -20.239 -81.970 8 15 1 4 1 2 4 8 + 47 -41.168 -42.023 1 16 1 4 1 2 4 8 + 48 79.199 -29.016 20 20 1 4 1 2 4 8 + 49 -20.728 -7.068 16 14 1 4 1 2 4 8 + 50 -4.163 -53.497 8 2 1 4 1 2 4 8 + 51 39.594 -40.460 16 5 1 4 1 2 4 8 + 52 -47.125 -77.850 25 16 1 4 1 2 4 8 + 53 -1.233 49.182 5 12 1 4 1 2 4 8 + 54 -0.372 -27.264 10 1 1 4 1 2 4 8 + 55 31.537 -8.722 24 15 1 4 1 2 4 8 + 56 -0.134 -20.264 16 5 1 4 1 2 4 8 + 57 66.394 -26.691 7 9 1 4 1 2 4 8 + 58 6.104 -64.093 14 8 1 4 1 2 4 8 + 59 13.544 -20.874 11 2 1 4 1 2 4 8 + 60 54.211 -6.537 15 10 1 4 1 2 4 8 + 61 22.046 -34.137 23 25 1 4 1 2 4 8 + 62 -9.723 4.706 5 24 1 4 1 2 4 8 + 63 -11.584 -46.857 16 7 1 4 1 2 4 8 + 64 -2.905 -0.305 13 14 1 4 1 2 4 8 + 65 13.837 -44.452 18 3 1 4 1 2 4 8 + 66 17.480 27.747 14 23 1 4 1 2 4 8 + 67 2.972 -43.689 3 21 1 4 1 2 4 8 + 68 -44.354 -38.202 22 13 1 4 1 2 4 8 + 69 -59.399 1.514 16 15 1 4 1 2 4 8 + 70 -13.452 -75.531 16 14 1 4 1 2 4 8 + 71 -5.518 -51.947 2 7 1 4 1 2 4 8 + 72 -9.589 -26.880 19 20 1 4 1 2 4 8 + 73 19.318 29.498 23 6 1 4 1 2 4 8 + 74 26.245 36.743 6 24 1 4 1 2 4 8 + 75 43.707 -28.033 11 17 1 4 1 2 4 8 + 76 -52.026 -35.339 19 3 1 4 1 2 4 8 + 77 -8.435 -0.116 3 15 1 4 1 2 4 8 + 78 89.111 62.122 14 6 1 4 1 2 4 8 + 79 6.067 -16.132 14 21 1 4 1 2 4 8 + 80 27.094 -5.103 19 25 1 4 1 2 4 8 + 81 27.527 -15.344 3 18 1 4 1 2 4 8 + 82 42.511 32.056 18 1 1 4 1 2 4 8 + 83 25.311 12.689 24 19 1 4 1 2 4 8 + 84 47.778 -12.769 6 17 1 4 1 2 4 8 + 85 -3.143 -13.837 1 20 1 4 1 2 4 8 + 86 12.482 -78.101 3 1 1 4 1 2 4 8 + 87 -21.039 -3.430 15 13 1 4 1 2 4 8 + 88 -3.149 -55.432 18 25 1 4 1 2 4 8 + 89 53.009 84.900 5 16 1 4 1 2 4 8 + 90 35.638 -47.552 23 5 1 4 1 2 4 8 + 91 43.427 -18.439 10 18 1 4 1 2 4 8 + 92 6.598 -54.578 20 17 1 4 1 2 4 8 + 93 87.952 94.012 11 15 1 4 1 2 4 8 + 94 39.105 -48.743 16 13 1 4 1 2 4 8 + 95 -48.340 -26.477 15 15 1 4 1 2 4 8 + 96 72.003 -9.253 19 2 1 4 1 2 4 8 + 97 -37.732 3.351 4 1 1 4 1 2 4 8 + 98 -65.967 -36.749 14 9 1 4 1 2 4 8 + 99 -16.669 -35.284 23 16 1 4 1 2 4 8 +100 10.742 -4.669 11 6 1 4 1 2 4 8 +101 15.594 -5.817 21 18 1 4 1 2 4 8 +102 21.606 -18.109 14 24 1 4 1 2 4 8 +103 9.784 49.280 16 24 1 4 1 2 4 8 +104 94.147 -4.492 25 9 1 4 1 2 4 8 +105 10.382 -16.302 17 19 1 4 1 2 4 8 +106 -1.453 -0.861 16 12 1 4 1 2 4 8 +107 -6.219 25.305 13 22 1 4 1 2 4 8 +108 -6.250 10.217 23 13 1 4 1 2 4 8 +109 -17.444 -70.795 10 20 1 4 1 2 4 8 +110 -55.090 -43.854 2 25 1 4 1 2 4 8 +111 -9.442 23.724 15 1 1 4 1 2 4 8 +112 8.978 35.406 14 24 1 4 1 2 4 8 +113 -16.754 -0.812 22 10 1 4 1 2 4 8 +114 66.852 -37.842 15 22 1 4 1 2 4 8 +115 14.716 -23.724 16 14 1 4 1 2 4 8 +116 33.472 20.026 12 12 1 4 1 2 4 8 +117 66.394 -70.111 14 23 1 4 1 2 4 8 +118 -5.664 8.881 15 14 1 4 1 2 4 8 +119 -5.103 -46.729 11 23 1 4 1 2 4 8 +120 -8.826 55.743 11 25 1 4 1 2 4 8 +121 5.847 -3.186 4 5 1 4 1 2 4 8 +122 -25.726 -37.695 23 7 1 4 1 2 4 8 +123 -15.363 -24.548 13 25 1 4 1 2 4 8 +124 43.793 -11.102 22 11 1 4 1 2 4 8 +125 17.664 -25.604 17 18 1 4 1 2 4 8 +126 -39.624 54.883 2 18 1 4 1 2 4 8 +127 -24.554 -43.225 5 1 1 4 1 2 4 8 +128 -26.892 -12.738 14 7 1 4 1 2 4 8 +129 34.155 -38.458 1 22 1 4 1 2 4 8 +130 -47.314 -29.468 13 7 1 4 1 2 4 8 +131 49.365 -25.592 8 3 1 4 1 2 4 8 +132 3.705 -16.449 24 18 1 4 1 2 4 8 +133 22.430 -23.273 12 8 1 4 1 2 4 8 +134 -37.549 -29.608 23 6 1 4 1 2 4 8 +135 25.549 3.674 1 7 1 4 1 2 4 8 +136 -15.216 3.284 2 20 1 4 1 2 4 8 +137 -12.939 -7.495 8 10 1 4 1 2 4 8 +138 -22.107 26.434 18 2 1 4 1 2 4 8 +139 -17.944 7.733 14 3 1 4 1 2 4 8 +140 -21.234 14.490 23 10 1 4 1 2 4 8 +141 3.503 -19.708 14 5 1 4 1 2 4 8 +142 32.599 -14.935 4 25 1 4 1 2 4 8 +143 -5.737 -28.296 24 23 1 4 1 2 4 8 +144 -6.128 -39.624 9 21 1 4 1 2 4 8 +145 -2.460 12.817 15 13 1 4 1 2 4 8 +146 -6.470 8.466 10 1 1 4 1 2 4 8 +147 -37.891 -36.115 3 11 1 4 1 2 4 8 +148 10.852 -18.750 12 6 1 4 1 2 4 8 +149 50.104 8.636 6 9 1 4 1 2 4 8 +150 46.844 4.712 1 17 1 4 1 2 4 8 +151 19.598 -10.406 24 13 1 4 1 2 4 8 +152 -38.947 52.942 3 23 1 4 1 2 4 8 +153 -0.641 -21.289 4 19 1 4 1 2 4 8 +154 40.906 -33.765 7 11 1 4 1 2 4 8 +155 -0.574 -62.299 21 12 1 4 1 2 4 8 +156 -9.778 26.794 1 18 1 4 1 2 4 8 +157 34.265 -23.895 24 25 1 4 1 2 4 8 +158 29.572 -24.561 5 13 1 4 1 2 4 8 +159 16.376 -58.887 23 24 1 4 1 2 4 8 +160 61.877 -15.167 5 5 1 4 1 2 4 8 +161 40.088 -9.625 17 14 1 4 1 2 4 8 +162 0.122 -4.645 24 18 1 4 1 2 4 8 +163 -8.929 -43.903 23 25 1 4 1 2 4 8 +164 -7.135 -57.434 3 11 1 4 1 2 4 8 +165 7.550 -21.210 5 18 1 4 1 2 4 8 +166 3.949 7.300 22 23 1 4 1 2 4 8 +167 -15.118 92.023 9 22 1 4 1 2 4 8 +168 84.821 -24.518 23 20 1 4 1 2 4 8 +169 -52.325 30.682 15 11 1 4 1 2 4 8 +170 7.538 13.818 15 11 1 4 1 2 4 8 +171 -21.484 30.359 11 19 1 4 1 2 4 8 +172 36.047 29.883 20 13 1 4 1 2 4 8 +173 12.781 -40.942 10 24 1 4 1 2 4 8 +174 -17.291 -10.254 24 6 1 4 1 2 4 8 +175 -10.541 12.402 10 5 1 4 1 2 4 8 +176 -15.845 -59.460 6 24 1 4 1 2 4 8 +177 29.266 -2.222 22 7 1 4 1 2 4 8 +178 -12.598 -58.929 25 13 1 4 1 2 4 8 +179 -17.303 -35.297 11 25 1 4 1 2 4 8 +180 57.050 -50.354 6 15 1 4 1 2 4 8 +181 26.941 17.444 9 15 1 4 1 2 4 8 +182 -6.195 -8.881 6 16 1 4 1 2 4 8 +183 16.980 -16.321 12 5 1 4 1 2 4 8 +184 83.710 -32.520 4 15 1 4 1 2 4 8 +185 12.451 34.589 24 24 1 4 1 2 4 8 +186 15.057 67.004 18 15 1 4 1 2 4 8 +187 25.818 -5.835 3 9 1 4 1 2 4 8 +188 13.666 -14.832 18 19 1 4 1 2 4 8 +189 48.322 -5.164 17 15 1 4 1 2 4 8 +190 13.489 19.739 23 2 1 4 1 2 4 8 +191 -18.512 65.405 10 3 1 4 1 2 4 8 +192 17.554 38.379 22 18 1 4 1 2 4 8 +193 37.775 -16.003 5 20 1 4 1 2 4 8 +194 47.968 -30.310 16 14 1 4 1 2 4 8 +195 38.806 36.243 10 10 1 4 1 2 4 8 +196 -16.089 -42.841 10 6 1 4 1 2 4 8 +197 28.656 -1.990 9 17 1 4 1 2 4 8 +198 -5.859 -1.862 5 20 1 4 1 2 4 8 +199 60.516 63.416 9 3 1 4 1 2 4 8 +200 63.196 -47.766 12 14 1 4 1 2 4 8 +201 -15.308 -23.285 16 12 1 4 1 2 4 8 +202 -2.875 0.787 8 2 1 4 1 2 4 8 +203 32.056 -10.175 1 11 1 4 1 2 4 8 +204 -18.634 -25.665 1 16 1 4 1 2 4 8 +205 -3.632 25.433 18 18 1 4 1 2 4 8 +206 10.480 22.888 22 14 1 4 1 2 4 8 +207 1.819 -3.009 20 6 1 4 1 2 4 8 +208 -25.275 -12.183 4 12 1 4 1 2 4 8 +209 56.927 -75.507 15 21 1 4 1 2 4 8 +210 13.885 -36.230 7 1 1 4 1 2 4 8 +211 32.520 -29.523 25 18 1 4 1 2 4 8 +212 4.803 -7.288 3 17 1 4 1 2 4 8 +213 11.365 -8.344 22 15 1 4 1 2 4 8 +214 17.126 -24.646 5 4 1 4 1 2 4 8 +215 -33.661 -41.241 1 18 1 4 1 2 4 8 +216 -32.391 -50.885 9 22 1 4 1 2 4 8 +217 23.041 -14.496 16 16 1 4 1 2 4 8 +218 -21.857 -39.502 23 14 1 4 1 2 4 8 +219 32.013 77.332 5 25 1 4 1 2 4 8 +220 13.831 -76.190 5 15 1 4 1 2 4 8 +221 -8.051 -21.179 6 6 1 4 1 2 4 8 +222 25.391 46.613 16 7 1 4 1 2 4 8 +223 49.536 -54.639 25 21 1 4 1 2 4 8 +224 63.416 -8.636 1 3 1 4 1 2 4 8 +225 2.301 -5.536 25 15 1 4 1 2 4 8 +226 52.423 29.895 17 24 1 4 1 2 4 8 +227 9.296 -16.254 11 2 1 4 1 2 4 8 +228 34.845 -96.185 24 17 1 4 1 2 4 8 +229 -21.063 -41.498 10 2 1 4 1 2 4 8 +230 28.448 10.242 12 25 1 4 1 2 4 8 +231 16.254 -22.583 17 15 1 4 1 2 4 8 +232 -36.639 -34.033 18 3 1 4 1 2 4 8 +233 -27.356 -50.177 5 1 1 4 1 2 4 8 +234 -53.705 11.334 16 1 1 4 1 2 4 8 +235 26.276 -5.994 9 20 1 4 1 2 4 8 +236 -31.519 34.589 6 19 1 4 1 2 4 8 +237 -14.612 -31.506 1 2 1 4 1 2 4 8 +238 -4.242 -30.865 4 9 1 4 1 2 4 8 +239 -18.524 -29.486 20 4 1 4 1 2 4 8 +240 -17.133 -19.397 19 16 1 4 1 2 4 8 +241 34.430 -17.151 0 0 0 0 +242 0.269 -8.154 0 0 0 0 +243 3.140 13.297 0 0 0 0 +244 -3.113 -29.745 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr05.res b/jsprit-instances/instances/cordeau/pr05.res new file mode 100644 index 00000000..818106fe --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr05.res @@ -0,0 +1,21 @@ +2385.77 +1 1 180.87 178.00 241 157 15 211 158 133 102 217 81 203 142 241 +1 2 290.67 178.00 241 161 124 189 150 149 226 8 82 116 230 28 135 55 241 +1 3 362.83 180.00 241 75 194 1 16 117 209 228 22 90 129 4 241 +1 4 295.55 178.00 241 154 51 39 94 223 180 19 200 114 57 131 33 91 241 +1 5 325.55 178.00 241 193 11 84 60 224 96 44 104 168 184 48 21 160 241 +2 1 309.84 174.00 242 225 207 5 145 3 205 107 13 111 108 146 118 202 162 242 +2 2 -0.00 0.00 242 242 +2 3 206.75 179.00 242 182 174 49 87 113 136 62 77 198 64 106 30 242 +2 4 252.37 178.00 242 85 221 240 201 123 204 239 34 14 7 128 208 137 242 +2 5 243.37 159.00 242 132 79 227 105 148 59 183 188 35 101 213 212 242 +3 1 227.25 158.00 243 32 206 185 192 24 73 66 190 9 243 +3 2 409.53 180.00 243 112 103 219 89 38 93 78 41 199 45 74 12 243 +3 3 392.34 178.00 243 53 120 191 167 31 186 222 6 195 172 181 83 170 243 +3 4 396.05 179.00 243 10 156 138 171 236 42 152 126 169 234 69 25 97 140 139 175 243 +3 5 233.28 176.00 243 37 197 177 80 20 235 187 29 151 100 121 166 243 +4 1 317.24 179.00 244 164 178 176 109 70 46 52 216 40 233 127 229 218 238 244 +4 2 267.39 180.00 244 163 119 71 50 88 155 58 86 220 159 92 67 244 +4 3 216.51 180.00 244 143 72 43 99 179 26 196 23 17 63 144 244 +4 4 251.38 179.00 244 18 54 153 56 141 165 115 231 214 125 61 65 173 210 36 244 +4 5 329.99 180.00 244 122 27 215 47 68 110 98 76 95 130 134 232 147 2 237 244 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr06 b/jsprit-instances/instances/cordeau/pr06 new file mode 100644 index 00000000..b8e77a68 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr06 @@ -0,0 +1,297 @@ +2 6 288 4 +400 175 +400 175 +400 175 +400 175 + 1 -66.174 -37.811 13 19 1 4 1 2 4 8 + 2 2.673 -35.223 16 21 1 4 1 2 4 8 + 3 38.751 8.618 1 17 1 4 1 2 4 8 + 4 62.653 20.667 9 6 1 4 1 2 4 8 + 5 60.974 -6.110 20 6 1 4 1 2 4 8 + 6 -98.535 -39.532 2 19 1 4 1 2 4 8 + 7 8.411 -81.274 5 17 1 4 1 2 4 8 + 8 -14.569 26.056 10 19 1 4 1 2 4 8 + 9 -34.186 -76.697 10 2 1 4 1 2 4 8 + 10 55.145 -33.911 25 3 1 4 1 2 4 8 + 11 15.869 8.716 2 24 1 4 1 2 4 8 + 12 -63.416 -20.282 5 5 1 4 1 2 4 8 + 13 -9.357 -42.212 16 9 1 4 1 2 4 8 + 14 -53.619 3.729 24 20 1 4 1 2 4 8 + 15 53.491 -3.308 7 19 1 4 1 2 4 8 + 16 -22.614 -32.794 19 20 1 4 1 2 4 8 + 17 39.612 -1.550 15 4 1 4 1 2 4 8 + 18 16.705 -22.748 7 3 1 4 1 2 4 8 + 19 -51.245 -13.757 16 2 1 4 1 2 4 8 + 20 -29.907 14.380 20 23 1 4 1 2 4 8 + 21 -70.441 -27.911 21 6 1 4 1 2 4 8 + 22 -75.385 -30.811 7 17 1 4 1 2 4 8 + 23 10.590 -28.931 17 17 1 4 1 2 4 8 + 24 86.340 -45.935 11 3 1 4 1 2 4 8 + 25 3.864 34.583 6 16 1 4 1 2 4 8 + 26 -37.598 -42.114 4 15 1 4 1 2 4 8 + 27 69.440 1.379 16 23 1 4 1 2 4 8 + 28 -13.818 1.245 8 15 1 4 1 2 4 8 + 29 -27.124 -38.037 13 12 1 4 1 2 4 8 + 30 -69.348 -14.734 25 19 1 4 1 2 4 8 + 31 58.575 29.346 16 23 1 4 1 2 4 8 + 32 58.105 31.702 2 10 1 4 1 2 4 8 + 33 -62.250 -16.425 12 23 1 4 1 2 4 8 + 34 -66.382 13.586 12 22 1 4 1 2 4 8 + 35 68.030 -12.482 14 4 1 4 1 2 4 8 + 36 -30.701 -41.681 16 5 1 4 1 2 4 8 + 37 -55.389 -51.050 9 1 1 4 1 2 4 8 + 38 36.237 -2.655 16 11 1 4 1 2 4 8 + 39 -1.215 5.591 2 20 1 4 1 2 4 8 + 40 10.278 -23.950 21 25 1 4 1 2 4 8 + 41 -7.159 36.859 7 18 1 4 1 2 4 8 + 42 -90.204 61.169 3 4 1 4 1 2 4 8 + 43 46.368 65.082 5 10 1 4 1 2 4 8 + 44 13.348 31.372 12 17 1 4 1 2 4 8 + 45 -73.566 -28.839 9 7 1 4 1 2 4 8 + 46 -41.528 -37.097 11 4 1 4 1 2 4 8 + 47 -60.938 -27.246 17 3 1 4 1 2 4 8 + 48 38.312 54.376 10 12 1 4 1 2 4 8 + 49 26.306 11.975 5 13 1 4 1 2 4 8 + 50 10.297 -48.346 3 24 1 4 1 2 4 8 + 51 52.417 -28.363 1 16 1 4 1 2 4 8 + 52 -43.756 -39.343 3 2 1 4 1 2 4 8 + 53 49.316 11.395 5 7 1 4 1 2 4 8 + 54 45.593 4.346 25 15 1 4 1 2 4 8 + 55 -25.989 -15.814 14 12 1 4 1 2 4 8 + 56 65.253 -59.631 4 15 1 4 1 2 4 8 + 57 12.109 -34.387 14 17 1 4 1 2 4 8 + 58 12.390 -16.254 20 16 1 4 1 2 4 8 + 59 0.525 69.611 5 1 1 4 1 2 4 8 + 60 -8.679 7.770 22 9 1 4 1 2 4 8 + 61 41.467 -35.016 17 4 1 4 1 2 4 8 + 62 11.859 -34.973 19 3 1 4 1 2 4 8 + 63 -1.306 -58.063 9 1 1 4 1 2 4 8 + 64 6.024 -31.018 16 4 1 4 1 2 4 8 + 65 1.788 -32.544 19 6 1 4 1 2 4 8 + 66 29.272 -6.494 11 1 1 4 1 2 4 8 + 67 23.950 10.742 6 19 1 4 1 2 4 8 + 68 -65.887 40.912 23 1 1 4 1 2 4 8 + 69 -10.095 26.257 24 2 1 4 1 2 4 8 + 70 58.093 67.352 21 25 1 4 1 2 4 8 + 71 90.015 9.485 16 4 1 4 1 2 4 8 + 72 -6.622 15.216 15 4 1 4 1 2 4 8 + 73 -2.875 -42.841 23 13 1 4 1 2 4 8 + 74 -37.714 -7.306 22 18 1 4 1 2 4 8 + 75 44.171 -11.224 21 9 1 4 1 2 4 8 + 76 -58.704 -2.808 21 5 1 4 1 2 4 8 + 77 -3.912 10.071 21 12 1 4 1 2 4 8 + 78 -41.370 -1.495 7 22 1 4 1 2 4 8 + 79 58.179 27.563 15 9 1 4 1 2 4 8 + 80 -63.861 26.147 15 11 1 4 1 2 4 8 + 81 -56.793 -15.918 16 6 1 4 1 2 4 8 + 82 22.217 -27.509 13 19 1 4 1 2 4 8 + 83 -1.031 -14.838 22 10 1 4 1 2 4 8 + 84 -57.703 -10.480 1 1 1 4 1 2 4 8 + 85 80.847 6.299 22 10 1 4 1 2 4 8 + 86 2.887 10.822 24 20 1 4 1 2 4 8 + 87 -37.390 -7.800 6 18 1 4 1 2 4 8 + 88 -33.600 -26.740 5 1 1 4 1 2 4 8 + 89 95.197 24.231 14 11 1 4 1 2 4 8 + 90 -13.904 29.327 19 20 1 4 1 2 4 8 + 91 -53.461 9.296 16 12 1 4 1 2 4 8 + 92 67.578 13.007 20 17 1 4 1 2 4 8 + 93 -83.881 -53.265 12 16 1 4 1 2 4 8 + 94 30.255 -72.430 7 3 1 4 1 2 4 8 + 95 -22.333 -20.538 23 14 1 4 1 2 4 8 + 96 3.741 -35.461 9 12 1 4 1 2 4 8 + 97 -20.093 -43.982 19 9 1 4 1 2 4 8 + 98 -47.687 -21.100 17 1 1 4 1 2 4 8 + 99 -20.447 -13.849 1 7 1 4 1 2 4 8 +100 34.515 3.967 25 7 1 4 1 2 4 8 +101 20.514 -11.884 12 5 1 4 1 2 4 8 +102 -46.039 -22.565 15 9 1 4 1 2 4 8 +103 -39.630 25.385 16 15 1 4 1 2 4 8 +104 -1.025 50.433 10 4 1 4 1 2 4 8 +105 -28.632 23.486 24 10 1 4 1 2 4 8 +106 -52.997 -16.248 24 21 1 4 1 2 4 8 +107 -3.345 -22.955 18 2 1 4 1 2 4 8 +108 -62.640 -26.349 21 6 1 4 1 2 4 8 +109 25.403 0.531 21 1 1 4 1 2 4 8 +110 -29.895 72.919 17 23 1 4 1 2 4 8 +111 26.630 1.971 7 24 1 4 1 2 4 8 +112 -9.814 35.004 14 16 1 4 1 2 4 8 +113 -7.758 -42.426 8 18 1 4 1 2 4 8 +114 28.918 -7.117 2 1 1 4 1 2 4 8 +115 47.693 36.108 18 1 1 4 1 2 4 8 +116 -53.168 5.206 10 21 1 4 1 2 4 8 +117 17.560 13.214 17 8 1 4 1 2 4 8 +118 6.836 -2.496 20 22 1 4 1 2 4 8 +119 -17.322 97.260 9 23 1 4 1 2 4 8 +120 22.406 26.532 25 11 1 4 1 2 4 8 +121 -73.090 -13.251 6 15 1 4 1 2 4 8 +122 -64.996 -4.578 16 14 1 4 1 2 4 8 +123 -34.906 -43.903 11 16 1 4 1 2 4 8 +124 -92.346 -4.517 9 25 1 4 1 2 4 8 +125 0.647 -8.496 9 12 1 4 1 2 4 8 +126 5.048 -37.323 18 9 1 4 1 2 4 8 +127 -19.080 -14.178 10 20 1 4 1 2 4 8 +128 -71.704 -11.450 11 22 1 4 1 2 4 8 +129 -45.581 -28.717 14 13 1 4 1 2 4 8 +130 -28.351 -23.914 15 24 1 4 1 2 4 8 +131 -16.486 30.920 19 13 1 4 1 2 4 8 +132 -83.423 -20.935 25 4 1 4 1 2 4 8 +133 -12.054 -20.612 10 22 1 4 1 2 4 8 +134 -7.184 -63.721 11 18 1 4 1 2 4 8 +135 34.546 -8.881 11 25 1 4 1 2 4 8 +136 -4.865 73.694 25 19 1 4 1 2 4 8 +137 -36.005 -3.876 14 8 1 4 1 2 4 8 +138 -28.400 -21.820 20 13 1 4 1 2 4 8 +139 -56.281 -15.112 7 1 1 4 1 2 4 8 +140 -11.017 42.151 1 1 1 4 1 2 4 8 +141 -63.092 -62.573 15 5 1 4 1 2 4 8 +142 29.486 79.944 2 2 1 4 1 2 4 8 +143 -65.674 -0.238 7 22 1 4 1 2 4 8 +144 46.130 -20.416 21 3 1 4 1 2 4 8 +145 1.575 -16.364 19 2 1 4 1 2 4 8 +146 40.277 -1.379 17 6 1 4 1 2 4 8 +147 -15.271 42.249 23 19 1 4 1 2 4 8 +148 33.215 -16.614 17 5 1 4 1 2 4 8 +149 -72.388 13.074 20 25 1 4 1 2 4 8 +150 -24.487 5.273 11 9 1 4 1 2 4 8 +151 -6.598 -30.957 1 20 1 4 1 2 4 8 +152 31.287 21.332 11 11 1 4 1 2 4 8 +153 20.557 0.378 15 18 1 4 1 2 4 8 +154 -67.200 -41.339 3 25 1 4 1 2 4 8 +155 22.168 -40.375 21 22 1 4 1 2 4 8 +156 31.165 2.222 5 25 1 4 1 2 4 8 +157 74.634 30.219 11 14 1 4 1 2 4 8 +158 60.699 81.116 6 21 1 4 1 2 4 8 +159 -60.736 24.133 17 1 1 4 1 2 4 8 +160 1.978 17.517 20 9 1 4 1 2 4 8 +161 -80.566 -38.196 10 2 1 4 1 2 4 8 +162 -49.927 -36.713 24 2 1 4 1 2 4 8 +163 -60.449 -27.820 6 4 1 4 1 2 4 8 +164 -78.748 -44.226 18 15 1 4 1 2 4 8 +165 54.260 -9.259 15 11 1 4 1 2 4 8 +166 -42.059 -26.636 6 15 1 4 1 2 4 8 +167 -57.336 -16.718 10 15 1 4 1 2 4 8 +168 -1.276 -13.330 7 16 1 4 1 2 4 8 +169 -24.158 39.197 24 14 1 4 1 2 4 8 +170 17.908 -40.442 3 25 1 4 1 2 4 8 +171 59.833 -3.674 22 9 1 4 1 2 4 8 +172 -3.510 6.256 1 23 1 4 1 2 4 8 +173 40.167 8.594 4 16 1 4 1 2 4 8 +174 -1.691 -54.376 12 10 1 4 1 2 4 8 +175 -36.035 -17.065 14 4 1 4 1 2 4 8 +176 7.275 -4.144 17 25 1 4 1 2 4 8 +177 30.219 -6.830 20 20 1 4 1 2 4 8 +178 -26.379 -63.055 19 5 1 4 1 2 4 8 +179 28.772 -0.031 18 19 1 4 1 2 4 8 +180 2.625 5.072 22 2 1 4 1 2 4 8 +181 3.595 -21.600 14 13 1 4 1 2 4 8 +182 -64.948 -10.956 14 19 1 4 1 2 4 8 +183 18.671 -41.010 20 2 1 4 1 2 4 8 +184 29.291 12.799 16 16 1 4 1 2 4 8 +185 4.529 26.654 25 2 1 4 1 2 4 8 +186 25.360 29.718 12 6 1 4 1 2 4 8 +187 57.349 -15.405 1 3 1 4 1 2 4 8 +188 -11.566 -19.012 11 20 1 4 1 2 4 8 +189 -45.441 -71.808 18 13 1 4 1 2 4 8 +190 2.197 -3.564 8 9 1 4 1 2 4 8 +191 -1.855 -24.475 8 5 1 4 1 2 4 8 +192 -59.851 -48.938 1 15 1 4 1 2 4 8 +193 70.081 -17.816 23 22 1 4 1 2 4 8 +194 -4.932 28.754 19 18 1 4 1 2 4 8 +195 -46.625 -23.529 18 21 1 4 1 2 4 8 +196 -49.872 -35.339 16 16 1 4 1 2 4 8 +197 -67.499 8.142 7 22 1 4 1 2 4 8 +198 31.195 -18.243 13 23 1 4 1 2 4 8 +199 -42.139 -52.704 5 1 1 4 1 2 4 8 +200 -15.094 18.933 3 1 1 4 1 2 4 8 +201 -78.625 -24.341 22 13 1 4 1 2 4 8 +202 51.471 -9.607 21 14 1 4 1 2 4 8 +203 29.987 -31.061 18 18 1 4 1 2 4 8 +204 46.741 1.453 14 5 1 4 1 2 4 8 +205 -52.954 31.738 19 24 1 4 1 2 4 8 +206 10.535 -61.432 18 11 1 4 1 2 4 8 +207 -15.948 -56.012 12 5 1 4 1 2 4 8 +208 -7.776 -54.730 21 1 1 4 1 2 4 8 +209 11.047 -20.905 15 21 1 4 1 2 4 8 +210 -24.359 -23.047 8 6 1 4 1 2 4 8 +211 2.948 -20.398 5 6 1 4 1 2 4 8 +212 -82.654 24.323 3 5 1 4 1 2 4 8 +213 -12.134 42.065 2 23 1 4 1 2 4 8 +214 -98.035 -36.359 5 16 1 4 1 2 4 8 +215 -61.102 -13.477 3 18 1 4 1 2 4 8 +216 -39.136 6.287 12 10 1 4 1 2 4 8 +217 41.180 7.971 4 9 1 4 1 2 4 8 +218 4.254 19.830 23 18 1 4 1 2 4 8 +219 -34.143 -37.915 8 22 1 4 1 2 4 8 +220 -4.559 23.566 7 24 1 4 1 2 4 8 +221 37.891 -1.947 10 15 1 4 1 2 4 8 +222 78.259 15.936 18 6 1 4 1 2 4 8 +223 -8.661 -25.110 4 12 1 4 1 2 4 8 +224 10.071 37.164 9 19 1 4 1 2 4 8 +225 -42.621 -46.985 19 19 1 4 1 2 4 8 +226 92.157 -94.183 5 17 1 4 1 2 4 8 +227 32.202 -39.844 19 22 1 4 1 2 4 8 +228 -55.231 -15.027 7 25 1 4 1 2 4 8 +229 -26.746 -21.490 22 11 1 4 1 2 4 8 +230 -75.513 -0.708 2 23 1 4 1 2 4 8 +231 34.021 12.665 7 10 1 4 1 2 4 8 +232 -2.643 -20.831 4 17 1 4 1 2 4 8 +233 53.369 13.770 11 6 1 4 1 2 4 8 +234 -14.948 -40.259 12 20 1 4 1 2 4 8 +235 67.828 5.750 2 6 1 4 1 2 4 8 +236 -13.220 -26.031 13 4 1 4 1 2 4 8 +237 4.169 -32.617 22 25 1 4 1 2 4 8 +238 -26.050 -33.313 6 7 1 4 1 2 4 8 +239 31.964 -45.703 11 11 1 4 1 2 4 8 +240 96.820 26.208 22 14 1 4 1 2 4 8 +241 -44.696 -37.854 9 14 1 4 1 2 4 8 +242 33.417 11.792 21 15 1 4 1 2 4 8 +243 -35.187 19.226 8 2 1 4 1 2 4 8 +244 -14.233 -74.988 4 14 1 4 1 2 4 8 +245 37.158 -0.836 19 17 1 4 1 2 4 8 +246 -51.697 -26.447 20 24 1 4 1 2 4 8 +247 23.535 5.896 22 10 1 4 1 2 4 8 +248 -18.433 53.711 10 20 1 4 1 2 4 8 +249 -11.340 -17.621 20 11 1 4 1 2 4 8 +250 -7.812 -35.895 10 16 1 4 1 2 4 8 +251 3.522 26.941 23 3 1 4 1 2 4 8 +252 -46.588 -22.266 5 11 1 4 1 2 4 8 +253 -2.997 -0.549 25 10 1 4 1 2 4 8 +254 32.147 17.151 7 18 1 4 1 2 4 8 +255 32.019 13.007 16 20 1 4 1 2 4 8 +256 -6.628 29.889 15 24 1 4 1 2 4 8 +257 77.777 -25.397 9 16 1 4 1 2 4 8 +258 30.707 65.704 19 2 1 4 1 2 4 8 +259 -43.811 -43.036 11 14 1 4 1 2 4 8 +260 49.561 16.827 19 10 1 4 1 2 4 8 +261 -28.931 -0.439 10 22 1 4 1 2 4 8 +262 40.363 16.382 20 14 1 4 1 2 4 8 +263 22.748 40.674 17 15 1 4 1 2 4 8 +264 -1.471 6.567 22 7 1 4 1 2 4 8 +265 -1.190 16.864 24 20 1 4 1 2 4 8 +266 8.032 41.821 5 1 1 4 1 2 4 8 +267 -44.019 -22.784 5 24 1 4 1 2 4 8 +268 12.366 -11.353 17 22 1 4 1 2 4 8 +269 33.276 15.881 7 23 1 4 1 2 4 8 +270 -34.790 -15.045 25 20 1 4 1 2 4 8 +271 -96.857 -19.391 12 15 1 4 1 2 4 8 +272 38.434 -5.353 11 14 1 4 1 2 4 8 +273 -25.391 0.220 6 12 1 4 1 2 4 8 +274 0.848 -31.860 13 4 1 4 1 2 4 8 +275 -24.023 95.691 23 15 1 4 1 2 4 8 +276 -4.272 35.468 15 12 1 4 1 2 4 8 +277 -6.927 1.855 13 8 1 4 1 2 4 8 +278 -70.953 -3.217 10 2 1 4 1 2 4 8 +279 -32.648 -16.522 24 24 1 4 1 2 4 8 +280 42.859 -21.680 13 5 1 4 1 2 4 8 +281 5.182 6.403 12 8 1 4 1 2 4 8 +282 36.920 -4.987 21 21 1 4 1 2 4 8 +283 49.591 27.783 10 5 1 4 1 2 4 8 +284 45.038 10.785 12 16 1 4 1 2 4 8 +285 7.690 14.056 9 8 1 4 1 2 4 8 +286 -60.907 18.640 5 24 1 4 1 2 4 8 +287 -64.496 8.923 18 23 1 4 1 2 4 8 +288 37.158 -14.990 24 6 1 4 1 2 4 8 +289 2.277 7.840 0 0 0 0 +290 32.883 -1.779 0 0 0 0 +291 -49.554 -17.828 0 0 0 0 +292 3.690 -26.099 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr06.res b/jsprit-instances/instances/cordeau/pr06.res new file mode 100644 index 00000000..969454f2 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr06.res @@ -0,0 +1,25 @@ +2723.27 +1 1 311.90 175.00 289 265 160 218 185 251 25 224 44 120 117 11 285 86 289 +1 2 386.46 172.00 289 8 90 131 169 248 110 275 119 136 59 104 266 289 +1 3 18.48 8.00 289 281 289 +1 4 250.20 173.00 289 77 72 69 256 112 147 213 140 41 276 194 220 289 +1 5 307.07 173.00 289 39 264 172 60 200 105 243 20 150 261 273 28 277 253 180 289 +1 6 -0.00 0.00 289 289 +2 1 355.16 165.00 290 177 66 114 101 198 148 288 75 202 165 5 171 15 146 17 221 38 290 +2 2 399.71 171.00 290 53 233 4 79 31 32 157 240 89 71 85 222 92 235 27 204 290 +2 3 389.33 170.00 290 269 254 152 186 263 258 142 158 70 43 48 115 283 260 217 290 +2 4 204.44 165.00 290 179 111 109 153 247 67 49 184 255 231 242 290 +2 5 188.60 148.00 290 156 100 3 173 262 284 54 245 282 290 +2 6 389.27 146.00 290 135 280 144 51 10 56 226 24 257 193 35 187 272 290 +3 1 271.25 174.00 291 246 196 162 241 52 259 225 199 123 36 219 26 46 102 252 291 +3 2 201.40 138.00 291 98 195 267 175 279 270 137 74 87 291 +3 3 226.95 174.00 291 19 14 116 91 286 34 287 197 143 76 84 291 +3 4 182.74 166.00 291 106 228 139 182 128 121 30 33 167 81 291 +3 5 387.72 175.00 291 78 216 103 205 159 80 68 42 212 149 230 278 122 215 291 +3 6 368.31 173.00 291 163 47 108 21 45 22 161 164 93 6 214 271 124 132 201 12 291 +4 1 262.73 175.00 292 274 65 2 73 113 13 234 97 29 238 16 250 151 292 +4 2 237.21 154.00 292 232 133 188 249 127 99 55 138 229 95 107 191 292 +4 3 331.41 168.00 292 237 96 126 174 63 134 244 7 94 206 50 62 57 64 292 +4 4 261.50 168.00 292 40 18 82 203 61 227 239 155 183 170 23 292 +4 5 392.33 166.00 292 208 207 178 9 189 141 37 192 154 1 129 166 88 130 210 236 223 292 +4 6 232.09 174.00 292 209 58 268 176 118 190 125 168 83 145 211 181 292 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr07 b/jsprit-instances/instances/cordeau/pr07 new file mode 100644 index 00000000..72bc45de --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr07 @@ -0,0 +1,85 @@ +2 1 72 6 +500 200 +500 200 +500 200 +500 200 +500 200 +500 200 + 1 -92.700 -59.180 8 20 1 6 1 2 4 8 16 32 + 2 71.179 12.543 15 6 1 6 1 2 4 8 16 32 + 3 31.537 66.638 20 19 1 6 1 2 4 8 16 32 + 4 -4.694 25.537 7 10 1 6 1 2 4 8 16 32 + 5 -30.194 67.773 13 18 1 6 1 2 4 8 16 32 + 6 12.677 -57.471 6 1 1 6 1 2 4 8 16 32 + 7 -32.355 -20.966 5 15 1 6 1 2 4 8 16 32 + 8 19.910 48.975 1 23 1 6 1 2 4 8 16 32 + 9 13.202 -19.135 12 13 1 6 1 2 4 8 16 32 + 10 54.877 -41.168 18 12 1 6 1 2 4 8 16 32 + 11 15.063 -25.171 25 7 1 6 1 2 4 8 16 32 + 12 -50.598 -16.418 14 25 1 6 1 2 4 8 16 32 + 13 -29.730 17.078 18 5 1 6 1 2 4 8 16 32 + 14 17.542 1.575 13 1 1 6 1 2 4 8 16 32 + 15 11.127 77.216 6 25 1 6 1 2 4 8 16 32 + 16 33.752 71.259 14 10 1 6 1 2 4 8 16 32 + 17 -56.012 -10.394 10 2 1 6 1 2 4 8 16 32 + 18 57.874 -16.290 18 7 1 6 1 2 4 8 16 32 + 19 10.718 -18.787 8 11 1 6 1 2 4 8 16 32 + 20 53.088 -18.750 6 4 1 6 1 2 4 8 16 32 + 21 1.569 7.532 2 6 1 6 1 2 4 8 16 32 + 22 31.531 48.944 4 15 1 6 1 2 4 8 16 32 + 23 -66.833 -37.854 4 7 1 6 1 2 4 8 16 32 + 24 -70.740 62.244 23 8 1 6 1 2 4 8 16 32 + 25 32.538 23.096 12 10 1 6 1 2 4 8 16 32 + 26 -51.453 -36.444 24 9 1 6 1 2 4 8 16 32 + 27 36.456 -22.638 17 4 1 6 1 2 4 8 16 32 + 28 -31.207 43.494 18 6 1 6 1 2 4 8 16 32 + 29 -10.388 34.491 25 22 1 6 1 2 4 8 16 32 + 30 14.722 -10.834 22 17 1 6 1 2 4 8 16 32 + 31 47.095 -21.387 10 9 1 6 1 2 4 8 16 32 + 32 43.781 34.766 25 25 1 6 1 2 4 8 16 32 + 33 53.546 -67.487 21 10 1 6 1 2 4 8 16 32 + 34 26.801 46.515 21 18 1 6 1 2 4 8 16 32 + 35 63.385 11.981 16 21 1 6 1 2 4 8 16 32 + 36 47.192 -5.475 23 10 1 6 1 2 4 8 16 32 + 37 -16.315 -11.267 21 23 1 6 1 2 4 8 16 32 + 38 78.900 17.651 15 23 1 6 1 2 4 8 16 32 + 39 79.822 22.272 7 11 1 6 1 2 4 8 16 32 + 40 12.878 16.919 20 1 1 6 1 2 4 8 16 32 + 41 -67.981 -3.754 6 23 1 6 1 2 4 8 16 32 + 42 9.198 -18.597 16 16 1 6 1 2 4 8 16 32 + 43 -35.950 -19.141 10 10 1 6 1 2 4 8 16 32 + 44 28.766 45.276 7 12 1 6 1 2 4 8 16 32 + 45 11.469 68.231 20 12 1 6 1 2 4 8 16 32 + 46 -22.760 45.496 9 3 1 6 1 2 4 8 16 32 + 47 -65.674 -23.120 12 22 1 6 1 2 4 8 16 32 + 48 7.239 1.599 10 21 1 6 1 2 4 8 16 32 + 49 -29.785 -11.285 19 13 1 6 1 2 4 8 16 32 + 50 -89.050 16.211 6 15 1 6 1 2 4 8 16 32 + 51 -46.887 -3.363 14 13 1 6 1 2 4 8 16 32 + 52 -14.972 30.621 23 20 1 6 1 2 4 8 16 32 + 53 -17.035 49.774 8 10 1 6 1 2 4 8 16 32 + 54 31.635 53.619 10 25 1 6 1 2 4 8 16 32 + 55 -3.577 13.342 14 7 1 6 1 2 4 8 16 32 + 56 33.008 58.960 3 15 1 6 1 2 4 8 16 32 + 57 -92.950 63.263 25 2 1 6 1 2 4 8 16 32 + 58 -9.137 -22.931 21 23 1 6 1 2 4 8 16 32 + 59 -39.960 6.195 5 5 1 6 1 2 4 8 16 32 + 60 28.430 -19.214 2 25 1 6 1 2 4 8 16 32 + 61 -28.540 -3.485 3 9 1 6 1 2 4 8 16 32 + 62 31.415 36.859 21 2 1 6 1 2 4 8 16 32 + 63 -49.426 60.602 1 24 1 6 1 2 4 8 16 32 + 64 -72.827 -27.765 25 13 1 6 1 2 4 8 16 32 + 65 60.083 -45.905 21 20 1 6 1 2 4 8 16 32 + 66 10.870 -3.900 21 13 1 6 1 2 4 8 16 32 + 67 25.122 7.672 25 15 1 6 1 2 4 8 16 32 + 68 -46.997 -17.474 14 4 1 6 1 2 4 8 16 32 + 69 16.058 33.020 20 20 1 6 1 2 4 8 16 32 + 70 25.409 -11.700 14 8 1 6 1 2 4 8 16 32 + 71 68.323 -5.145 11 19 1 6 1 2 4 8 16 32 + 72 -13.104 62.158 25 20 1 6 1 2 4 8 16 32 + 73 42.395 -8.344 0 0 0 0 + 74 -42.175 -14.554 0 0 0 0 + 75 16.034 40.726 0 0 0 0 + 76 -14.639 29.633 0 0 0 0 + 77 16.049 -3.934 0 0 0 0 + 78 46.112 12.430 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr07.res b/jsprit-instances/instances/cordeau/pr07.res new file mode 100644 index 00000000..b61ec122 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr07.res @@ -0,0 +1,7 @@ +1089.56 +1 1 492.15 193.00 73 27 60 70 30 42 19 9 11 6 33 65 10 31 20 18 71 36 73 +2 1 400.02 193.00 74 49 61 37 58 7 43 26 23 1 64 47 12 68 74 +3 1 272.66 196.00 75 69 62 44 34 22 54 56 3 16 15 45 8 75 +4 1 484.52 174.00 76 13 59 51 17 41 50 57 24 63 5 72 53 46 28 52 76 +5 1 247.53 96.00 77 66 48 21 55 4 29 40 67 14 77 +6 1 200.68 96.00 78 35 2 38 39 32 25 78 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr08 b/jsprit-instances/instances/cordeau/pr08 new file mode 100644 index 00000000..34b7ae17 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr08 @@ -0,0 +1,157 @@ +2 2 144 6 +475 190 +475 190 +475 190 +475 190 +475 190 +475 190 + 1 -40.289 -42.303 6 20 1 6 1 2 4 8 16 32 + 2 -64.709 -17.389 3 10 1 6 1 2 4 8 16 32 + 3 5.060 -14.349 23 8 1 6 1 2 4 8 16 32 + 4 72.095 20.233 1 6 1 6 1 2 4 8 16 32 + 5 2.594 -15.002 18 1 1 6 1 2 4 8 16 32 + 6 -24.176 -72.894 8 19 1 6 1 2 4 8 16 32 + 7 -13.190 66.498 2 13 1 6 1 2 4 8 16 32 + 8 33.191 13.690 9 24 1 6 1 2 4 8 16 32 + 9 66.827 -30.554 1 15 1 6 1 2 4 8 16 32 + 10 19.934 35.883 20 13 1 6 1 2 4 8 16 32 + 11 -27.771 32.269 23 10 1 6 1 2 4 8 16 32 + 12 51.154 -16.827 22 4 1 6 1 2 4 8 16 32 + 13 -19.214 23.749 24 12 1 6 1 2 4 8 16 32 + 14 -46.643 -52.954 21 21 1 6 1 2 4 8 16 32 + 15 -10.590 -16.626 18 2 1 6 1 2 4 8 16 32 + 16 35.150 12.622 21 10 1 6 1 2 4 8 16 32 + 17 -37.378 12.256 7 20 1 6 1 2 4 8 16 32 + 18 82.794 25.836 4 9 1 6 1 2 4 8 16 32 + 19 8.936 -3.723 21 24 1 6 1 2 4 8 16 32 + 20 -56.659 25.555 13 19 1 6 1 2 4 8 16 32 + 21 -52.020 -40.137 18 13 1 6 1 2 4 8 16 32 + 22 39.270 12.787 4 14 1 6 1 2 4 8 16 32 + 23 19.757 21.228 3 17 1 6 1 2 4 8 16 32 + 24 -23.071 -12.659 12 25 1 6 1 2 4 8 16 32 + 25 15.686 52.374 5 1 1 6 1 2 4 8 16 32 + 26 58.771 -7.056 8 9 1 6 1 2 4 8 16 32 + 27 -33.087 72.266 14 12 1 6 1 2 4 8 16 32 + 28 2.551 46.851 10 22 1 6 1 2 4 8 16 32 + 29 -18.719 73.126 14 2 1 6 1 2 4 8 16 32 + 30 -67.627 -20.679 19 21 1 6 1 2 4 8 16 32 + 31 -76.862 -11.365 20 8 1 6 1 2 4 8 16 32 + 32 -24.194 -38.263 21 19 1 6 1 2 4 8 16 32 + 33 -20.374 -31.903 11 24 1 6 1 2 4 8 16 32 + 34 9.290 39.618 14 24 1 6 1 2 4 8 16 32 + 35 26.044 35.974 6 2 1 6 1 2 4 8 16 32 + 36 -57.385 -45.264 7 20 1 6 1 2 4 8 16 32 + 37 1.489 -62.592 3 20 1 6 1 2 4 8 16 32 + 38 34.937 13.672 22 5 1 6 1 2 4 8 16 32 + 39 -22.290 45.648 21 17 1 6 1 2 4 8 16 32 + 40 -5.920 44.061 12 4 1 6 1 2 4 8 16 32 + 41 -38.446 -23.541 1 21 1 6 1 2 4 8 16 32 + 42 28.894 33.936 11 3 1 6 1 2 4 8 16 32 + 43 -35.388 -5.341 12 16 1 6 1 2 4 8 16 32 + 44 -19.501 13.519 19 14 1 6 1 2 4 8 16 32 + 45 -9.216 -30.988 8 6 1 6 1 2 4 8 16 32 + 46 -22.131 -17.065 11 5 1 6 1 2 4 8 16 32 + 47 -22.827 36.810 18 12 1 6 1 2 4 8 16 32 + 48 -61.365 -18.463 6 23 1 6 1 2 4 8 16 32 + 49 50.128 -66.046 3 12 1 6 1 2 4 8 16 32 + 50 25.647 24.139 6 18 1 6 1 2 4 8 16 32 + 51 65.521 42.810 10 24 1 6 1 2 4 8 16 32 + 52 -60.956 -47.925 7 3 1 6 1 2 4 8 16 32 + 53 -9.070 42.798 17 3 1 6 1 2 4 8 16 32 + 54 -19.061 4.480 12 25 1 6 1 2 4 8 16 32 + 55 -54.071 -3.870 11 22 1 6 1 2 4 8 16 32 + 56 -25.598 -18.866 15 25 1 6 1 2 4 8 16 32 + 57 -18.707 84.296 6 15 1 6 1 2 4 8 16 32 + 58 -70.184 -39.166 13 18 1 6 1 2 4 8 16 32 + 59 -14.636 -0.446 3 8 1 6 1 2 4 8 16 32 + 60 -76.465 -38.922 23 20 1 6 1 2 4 8 16 32 + 61 44.092 12.433 24 18 1 6 1 2 4 8 16 32 + 62 -22.772 -50.867 22 5 1 6 1 2 4 8 16 32 + 63 19.104 44.672 11 25 1 6 1 2 4 8 16 32 + 64 -44.019 -39.935 24 16 1 6 1 2 4 8 16 32 + 65 -2.972 -4.059 8 14 1 6 1 2 4 8 16 32 + 66 -24.261 35.907 22 1 1 6 1 2 4 8 16 32 + 67 -61.877 -73.901 11 15 1 6 1 2 4 8 16 32 + 68 -5.640 -26.721 6 22 1 6 1 2 4 8 16 32 + 69 45.844 -36.835 10 6 1 6 1 2 4 8 16 32 + 70 -51.746 -79.840 10 24 1 6 1 2 4 8 16 32 + 71 -33.008 10.992 20 19 1 6 1 2 4 8 16 32 + 72 -25.653 -0.372 2 12 1 6 1 2 4 8 16 32 + 73 -21.497 61.487 18 13 1 6 1 2 4 8 16 32 + 74 2.032 26.727 8 10 1 6 1 2 4 8 16 32 + 75 -26.758 14.807 13 12 1 6 1 2 4 8 16 32 + 76 -37.256 -44.861 8 13 1 6 1 2 4 8 16 32 + 77 -0.861 -16.418 8 25 1 6 1 2 4 8 16 32 + 78 -51.160 34.967 18 12 1 6 1 2 4 8 16 32 + 79 -41.266 -76.886 17 2 1 6 1 2 4 8 16 32 + 80 -30.255 74.701 10 11 1 6 1 2 4 8 16 32 + 81 -46.368 -1.514 23 10 1 6 1 2 4 8 16 32 + 82 -71.619 73.077 3 9 1 6 1 2 4 8 16 32 + 83 -46.606 -39.948 25 21 1 6 1 2 4 8 16 32 + 84 -30.243 67.102 4 14 1 6 1 2 4 8 16 32 + 85 -40.997 -43.036 25 15 1 6 1 2 4 8 16 32 + 86 -74.286 -52.307 5 6 1 6 1 2 4 8 16 32 + 87 -17.609 -71.851 9 25 1 6 1 2 4 8 16 32 + 88 2.350 -81.805 18 14 1 6 1 2 4 8 16 32 + 89 -85.486 -54.059 16 17 1 6 1 2 4 8 16 32 + 90 23.822 10.571 16 8 1 6 1 2 4 8 16 32 + 91 -24.530 -31.726 22 4 1 6 1 2 4 8 16 32 + 92 -42.474 -15.009 2 17 1 6 1 2 4 8 16 32 + 93 -33.624 50.330 22 23 1 6 1 2 4 8 16 32 + 94 -81.458 -41.565 11 4 1 6 1 2 4 8 16 32 + 95 -73.505 -48.279 24 4 1 6 1 2 4 8 16 32 + 96 -3.052 70.898 17 9 1 6 1 2 4 8 16 32 + 97 0.946 25.458 12 9 1 6 1 2 4 8 16 32 + 98 -54.144 13.525 1 19 1 6 1 2 4 8 16 32 + 99 -30.634 7.526 23 12 1 6 1 2 4 8 16 32 +100 -68.335 -34.277 4 25 1 6 1 2 4 8 16 32 +101 7.178 57.935 15 8 1 6 1 2 4 8 16 32 +102 4.712 48.669 15 13 1 6 1 2 4 8 16 32 +103 58.087 26.379 12 3 1 6 1 2 4 8 16 32 +104 18.347 34.784 21 6 1 6 1 2 4 8 16 32 +105 -44.629 -61.975 21 11 1 6 1 2 4 8 16 32 +106 5.231 26.068 15 24 1 6 1 2 4 8 16 32 +107 -48.065 -36.755 21 16 1 6 1 2 4 8 16 32 +108 -3.589 -27.734 19 21 1 6 1 2 4 8 16 32 +109 9.808 36.896 11 25 1 6 1 2 4 8 16 32 +110 59.460 1.233 3 10 1 6 1 2 4 8 16 32 +111 -47.522 19.873 12 2 1 6 1 2 4 8 16 32 +112 -48.431 -50.317 4 13 1 6 1 2 4 8 16 32 +113 44.666 20.953 2 14 1 6 1 2 4 8 16 32 +114 -19.226 32.770 9 19 1 6 1 2 4 8 16 32 +115 -15.662 17.462 21 16 1 6 1 2 4 8 16 32 +116 -91.669 77.722 17 23 1 6 1 2 4 8 16 32 +117 -30.035 -78.284 22 13 1 6 1 2 4 8 16 32 +118 73.663 32.941 24 24 1 6 1 2 4 8 16 32 +119 22.400 -60.083 2 17 1 6 1 2 4 8 16 32 +120 61.206 -13.501 25 8 1 6 1 2 4 8 16 32 +121 22.131 -50.012 21 12 1 6 1 2 4 8 16 32 +122 -6.317 56.665 11 6 1 6 1 2 4 8 16 32 +123 -20.471 12.885 23 20 1 6 1 2 4 8 16 32 +124 -61.084 -44.769 4 20 1 6 1 2 4 8 16 32 +125 -9.576 -19.366 1 24 1 6 1 2 4 8 16 32 +126 5.627 -88.501 15 10 1 6 1 2 4 8 16 32 +127 -2.618 22.131 20 18 1 6 1 2 4 8 16 32 +128 40.497 32.343 8 10 1 6 1 2 4 8 16 32 +129 -3.296 36.774 4 15 1 6 1 2 4 8 16 32 +130 -50.995 19.781 12 12 1 6 1 2 4 8 16 32 +131 -70.520 -3.809 23 22 1 6 1 2 4 8 16 32 +132 4.205 0.812 25 11 1 6 1 2 4 8 16 32 +133 9.955 26.337 5 14 1 6 1 2 4 8 16 32 +134 13.538 -21.313 15 9 1 6 1 2 4 8 16 32 +135 -21.869 -18.768 2 6 1 6 1 2 4 8 16 32 +136 -37.158 -30.768 22 23 1 6 1 2 4 8 16 32 +137 -86.975 10.345 16 8 1 6 1 2 4 8 16 32 +138 -47.272 -46.326 23 22 1 6 1 2 4 8 16 32 +139 4.095 -19.354 13 7 1 6 1 2 4 8 16 32 +140 4.205 30.292 7 15 1 6 1 2 4 8 16 32 +141 -42.017 53.986 20 22 1 6 1 2 4 8 16 32 +142 35.095 -10.895 25 7 1 6 1 2 4 8 16 32 +143 61.188 -59.875 12 14 1 6 1 2 4 8 16 32 +144 -34.674 -1.337 9 21 1 6 1 2 4 8 16 32 +145 -3.799 44.290 0 0 0 0 +146 14.233 21.173 0 0 0 0 +147 -23.334 -28.397 0 0 0 0 +148 10.065 1.822 0 0 0 0 +149 -49.115 -43.549 0 0 0 0 +150 -21.054 4.144 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr08.res b/jsprit-instances/instances/cordeau/pr08.res new file mode 100644 index 00000000..bda029e6 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr08.res @@ -0,0 +1,13 @@ +1666.60 +1 1 270.50 176.00 145 40 53 129 140 109 34 104 10 35 63 25 101 102 28 145 +1 2 432.14 189.00 145 39 93 141 116 82 84 27 80 57 29 73 7 96 122 145 +2 1 345.65 190.00 146 90 8 38 16 22 61 113 103 4 18 118 51 128 42 50 146 +2 2 14.05 17.00 146 23 146 +3 1 250.79 168.00 147 41 136 107 83 64 85 1 76 32 91 147 +3 2 216.60 186.00 147 56 135 46 24 15 125 77 5 68 108 45 33 147 +4 1 464.59 162.00 148 19 3 139 134 121 119 49 143 69 9 120 26 110 12 142 148 +4 2 272.55 183.00 148 132 65 59 54 123 44 115 127 97 74 106 133 148 +5 1 375.06 179.00 149 14 105 67 70 79 117 6 87 126 88 37 62 149 +5 2 263.76 185.00 149 21 100 58 60 94 89 86 95 52 124 36 112 138 149 +6 1 312.13 190.00 150 144 81 55 131 137 31 30 2 48 92 43 72 150 +6 2 348.78 181.00 150 75 13 114 47 66 11 78 20 98 130 111 17 71 99 150 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr09 b/jsprit-instances/instances/cordeau/pr09 new file mode 100644 index 00000000..2d53e498 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr09 @@ -0,0 +1,229 @@ +2 3 216 6 +450 180 +450 180 +450 180 +450 180 +450 180 +450 180 + 1 -41.235 -66.357 14 3 1 6 1 2 4 8 16 32 + 2 34.064 -59.357 16 16 1 6 1 2 4 8 16 32 + 3 20.917 -52.582 17 8 1 6 1 2 4 8 16 32 + 4 -38.538 -37.396 19 15 1 6 1 2 4 8 16 32 + 5 41.058 22.931 6 12 1 6 1 2 4 8 16 32 + 6 -54.034 -53.131 7 13 1 6 1 2 4 8 16 32 + 7 8.099 80.725 3 8 1 6 1 2 4 8 16 32 + 8 81.299 13.409 10 24 1 6 1 2 4 8 16 32 + 9 14.459 -2.972 4 14 1 6 1 2 4 8 16 32 + 10 -52.539 60.107 17 17 1 6 1 2 4 8 16 32 + 11 -57.202 -34.229 10 8 1 6 1 2 4 8 16 32 + 12 -65.552 -40.222 13 11 1 6 1 2 4 8 16 32 + 13 -19.751 -10.278 20 8 1 6 1 2 4 8 16 32 + 14 -26.965 -87.012 6 17 1 6 1 2 4 8 16 32 + 15 3.192 -88.654 18 19 1 6 1 2 4 8 16 32 + 16 34.521 32.837 3 13 1 6 1 2 4 8 16 32 + 17 80.035 5.273 10 2 1 6 1 2 4 8 16 32 + 18 -39.838 -67.731 4 8 1 6 1 2 4 8 16 32 + 19 14.600 11.365 15 21 1 6 1 2 4 8 16 32 + 20 -20.990 -80.511 4 13 1 6 1 2 4 8 16 32 + 21 48.242 47.284 6 17 1 6 1 2 4 8 16 32 + 22 59.338 -31.860 19 4 1 6 1 2 4 8 16 32 + 23 -13.995 -45.624 7 22 1 6 1 2 4 8 16 32 + 24 32.397 -32.532 20 24 1 6 1 2 4 8 16 32 + 25 2.826 50.824 12 11 1 6 1 2 4 8 16 32 + 26 -66.077 -34.686 8 6 1 6 1 2 4 8 16 32 + 27 -13.660 18.640 18 19 1 6 1 2 4 8 16 32 + 28 -59.344 12.769 1 11 1 6 1 2 4 8 16 32 + 29 -5.133 -18.463 25 23 1 6 1 2 4 8 16 32 + 30 -22.961 -21.729 16 4 1 6 1 2 4 8 16 32 + 31 58.130 46.606 5 5 1 6 1 2 4 8 16 32 + 32 -49.603 -76.624 7 16 1 6 1 2 4 8 16 32 + 33 -4.803 43.036 20 2 1 6 1 2 4 8 16 32 + 34 68.616 -19.623 3 13 1 6 1 2 4 8 16 32 + 35 37.915 63.599 11 11 1 6 1 2 4 8 16 32 + 36 1.251 -26.550 15 9 1 6 1 2 4 8 16 32 + 37 -37.952 1.685 15 18 1 6 1 2 4 8 16 32 + 38 -40.503 8.038 8 7 1 6 1 2 4 8 16 32 + 39 -8.392 -38.678 13 24 1 6 1 2 4 8 16 32 + 40 -36.725 25.494 16 5 1 6 1 2 4 8 16 32 + 41 -47.754 -50.073 4 2 1 6 1 2 4 8 16 32 + 42 22.595 -28.357 9 5 1 6 1 2 4 8 16 32 + 43 -36.365 -48.163 5 5 1 6 1 2 4 8 16 32 + 44 75.452 -13.422 20 3 1 6 1 2 4 8 16 32 + 45 -64.520 -13.232 10 13 1 6 1 2 4 8 16 32 + 46 1.257 29.156 9 2 1 6 1 2 4 8 16 32 + 47 -1.569 -35.974 18 10 1 6 1 2 4 8 16 32 + 48 46.747 6.696 13 12 1 6 1 2 4 8 16 32 + 49 82.080 27.057 17 24 1 6 1 2 4 8 16 32 + 50 74.695 19.366 22 21 1 6 1 2 4 8 16 32 + 51 47.015 9.338 5 18 1 6 1 2 4 8 16 32 + 52 -62.036 -21.326 12 5 1 6 1 2 4 8 16 32 + 53 9.192 20.038 4 15 1 6 1 2 4 8 16 32 + 54 -3.094 21.582 5 11 1 6 1 2 4 8 16 32 + 55 -75.446 13.086 22 7 1 6 1 2 4 8 16 32 + 56 10.034 -63.739 7 3 1 6 1 2 4 8 16 32 + 57 71.814 26.501 12 17 1 6 1 2 4 8 16 32 + 58 18.842 -38.019 10 14 1 6 1 2 4 8 16 32 + 59 -10.541 -31.305 18 14 1 6 1 2 4 8 16 32 + 60 8.252 -91.150 17 7 1 6 1 2 4 8 16 32 + 61 72.821 -38.916 3 12 1 6 1 2 4 8 16 32 + 62 -30.157 38.776 1 5 1 6 1 2 4 8 16 32 + 63 -56.256 -5.548 9 11 1 6 1 2 4 8 16 32 + 64 -8.398 -37.604 12 17 1 6 1 2 4 8 16 32 + 65 15.021 13.708 4 3 1 6 1 2 4 8 16 32 + 66 -60.199 24.292 2 7 1 6 1 2 4 8 16 32 + 67 -13.794 -27.106 18 13 1 6 1 2 4 8 16 32 + 68 -34.796 -22.205 23 20 1 6 1 2 4 8 16 32 + 69 69.641 83.057 14 13 1 6 1 2 4 8 16 32 + 70 -44.440 30.090 6 4 1 6 1 2 4 8 16 32 + 71 48.633 3.021 1 3 1 6 1 2 4 8 16 32 + 72 -15.314 51.709 6 24 1 6 1 2 4 8 16 32 + 73 36.261 26.782 6 23 1 6 1 2 4 8 16 32 + 74 59.961 24.310 8 21 1 6 1 2 4 8 16 32 + 75 55.304 6.628 25 23 1 6 1 2 4 8 16 32 + 76 39.960 48.297 3 10 1 6 1 2 4 8 16 32 + 77 -48.895 -71.100 3 21 1 6 1 2 4 8 16 32 + 78 -2.338 -62.909 16 24 1 6 1 2 4 8 16 32 + 79 9.491 -41.901 5 9 1 6 1 2 4 8 16 32 + 80 -54.675 -18.439 6 22 1 6 1 2 4 8 16 32 + 81 10.980 -7.605 6 3 1 6 1 2 4 8 16 32 + 82 -69.824 -50.354 16 6 1 6 1 2 4 8 16 32 + 83 -40.308 -7.452 6 11 1 6 1 2 4 8 16 32 + 84 62.244 43.628 13 10 1 6 1 2 4 8 16 32 + 85 29.077 63.116 4 15 1 6 1 2 4 8 16 32 + 86 -12.067 -21.509 12 9 1 6 1 2 4 8 16 32 + 87 14.728 28.906 15 20 1 6 1 2 4 8 16 32 + 88 -63.086 -60.114 10 19 1 6 1 2 4 8 16 32 + 89 33.655 -0.928 19 19 1 6 1 2 4 8 16 32 + 90 -12.225 14.148 19 19 1 6 1 2 4 8 16 32 + 91 -89.966 51.514 1 20 1 6 1 2 4 8 16 32 + 92 -0.763 41.339 22 1 1 6 1 2 4 8 16 32 + 93 80.695 32.983 20 15 1 6 1 2 4 8 16 32 + 94 -53.394 -14.240 5 18 1 6 1 2 4 8 16 32 + 95 -53.284 -64.136 12 2 1 6 1 2 4 8 16 32 + 96 73.260 10.669 4 25 1 6 1 2 4 8 16 32 + 97 59.613 13.452 12 20 1 6 1 2 4 8 16 32 + 98 -37.012 6.476 8 18 1 6 1 2 4 8 16 32 + 99 -53.656 21.692 10 8 1 6 1 2 4 8 16 32 +100 -36.890 18.372 2 3 1 6 1 2 4 8 16 32 +101 -4.608 -13.806 25 2 1 6 1 2 4 8 16 32 +102 53.802 36.993 14 15 1 6 1 2 4 8 16 32 +103 48.468 -66.040 20 21 1 6 1 2 4 8 16 32 +104 -46.393 -20.929 11 6 1 6 1 2 4 8 16 32 +105 -15.045 -40.845 4 24 1 6 1 2 4 8 16 32 +106 -73.621 -9.552 6 19 1 6 1 2 4 8 16 32 +107 92.847 45.587 8 23 1 6 1 2 4 8 16 32 +108 33.557 28.064 5 16 1 6 1 2 4 8 16 32 +109 47.321 24.414 3 16 1 6 1 2 4 8 16 32 +110 -6.610 -30.157 4 9 1 6 1 2 4 8 16 32 +111 12.103 23.840 24 1 1 6 1 2 4 8 16 32 +112 -61.963 26.239 4 10 1 6 1 2 4 8 16 32 +113 23.877 9.808 11 14 1 6 1 2 4 8 16 32 +114 49.780 6.866 23 11 1 6 1 2 4 8 16 32 +115 -53.021 -21.484 1 4 1 6 1 2 4 8 16 32 +116 54.962 2.985 15 23 1 6 1 2 4 8 16 32 +117 4.865 -69.586 12 23 1 6 1 2 4 8 16 32 +118 33.948 45.209 10 22 1 6 1 2 4 8 16 32 +119 -32.166 -23.621 24 11 1 6 1 2 4 8 16 32 +120 -17.548 -46.765 5 14 1 6 1 2 4 8 16 32 +121 31.744 33.972 23 12 1 6 1 2 4 8 16 32 +122 45.374 22.131 15 13 1 6 1 2 4 8 16 32 +123 -5.219 -23.114 6 11 1 6 1 2 4 8 16 32 +124 -51.056 -46.545 20 9 1 6 1 2 4 8 16 32 +125 11.774 11.133 13 6 1 6 1 2 4 8 16 32 +126 -39.758 -13.019 3 25 1 6 1 2 4 8 16 32 +127 27.930 29.321 3 21 1 6 1 2 4 8 16 32 +128 33.740 66.595 25 13 1 6 1 2 4 8 16 32 +129 -91.815 29.858 15 23 1 6 1 2 4 8 16 32 +130 -24.628 -68.701 6 8 1 6 1 2 4 8 16 32 +131 44.659 20.465 4 7 1 6 1 2 4 8 16 32 +132 45.447 -21.069 14 8 1 6 1 2 4 8 16 32 +133 -37.366 -12.097 15 9 1 6 1 2 4 8 16 32 +134 41.998 0.153 17 2 1 6 1 2 4 8 16 32 +135 -42.822 -30.170 12 24 1 6 1 2 4 8 16 32 +136 34.906 -4.578 2 7 1 6 1 2 4 8 16 32 +137 -65.137 -43.079 11 23 1 6 1 2 4 8 16 32 +138 20.270 -4.999 5 21 1 6 1 2 4 8 16 32 +139 -36.731 -8.929 20 12 1 6 1 2 4 8 16 32 +140 -26.984 -19.568 16 23 1 6 1 2 4 8 16 32 +141 -31.299 -83.813 13 18 1 6 1 2 4 8 16 32 +142 -26.794 12.506 9 5 1 6 1 2 4 8 16 32 +143 -39.362 -58.521 23 15 1 6 1 2 4 8 16 32 +144 -34.369 0.610 11 11 1 6 1 2 4 8 16 32 +145 43.372 4.187 14 8 1 6 1 2 4 8 16 32 +146 -38.226 -9.448 3 2 1 6 1 2 4 8 16 32 +147 -25.610 -99.237 9 6 1 6 1 2 4 8 16 32 +148 48.059 29.517 21 23 1 6 1 2 4 8 16 32 +149 -43.628 -32.318 24 9 1 6 1 2 4 8 16 32 +150 -16.602 -29.327 4 1 1 6 1 2 4 8 16 32 +151 -29.810 -12.408 18 12 1 6 1 2 4 8 16 32 +152 -51.910 -28.711 10 17 1 6 1 2 4 8 16 32 +153 -1.801 -18.671 3 2 1 6 1 2 4 8 16 32 +154 18.738 21.399 4 5 1 6 1 2 4 8 16 32 +155 60.120 7.788 25 1 1 6 1 2 4 8 16 32 +156 43.079 42.017 3 20 1 6 1 2 4 8 16 32 +157 -39.435 -5.902 22 19 1 6 1 2 4 8 16 32 +158 -35.889 -16.034 19 13 1 6 1 2 4 8 16 32 +159 -41.827 38.995 20 10 1 6 1 2 4 8 16 32 +160 84.497 29.822 7 9 1 6 1 2 4 8 16 32 +161 -17.560 -10.480 19 14 1 6 1 2 4 8 16 32 +162 -48.383 -48.920 19 4 1 6 1 2 4 8 16 32 +163 -49.335 -17.969 22 20 1 6 1 2 4 8 16 32 +164 16.095 -2.490 4 17 1 6 1 2 4 8 16 32 +165 65.527 14.026 25 19 1 6 1 2 4 8 16 32 +166 -2.930 13.220 23 19 1 6 1 2 4 8 16 32 +167 -18.768 -23.663 24 16 1 6 1 2 4 8 16 32 +168 -91.095 -80.737 25 4 1 6 1 2 4 8 16 32 +169 -21.088 -13.293 4 1 1 6 1 2 4 8 16 32 +170 46.985 17.224 3 21 1 6 1 2 4 8 16 32 +171 -61.957 -33.038 7 9 1 6 1 2 4 8 16 32 +172 -9.003 -25.452 10 2 1 6 1 2 4 8 16 32 +173 33.661 -7.666 10 24 1 6 1 2 4 8 16 32 +174 -25.592 -10.840 23 1 1 6 1 2 4 8 16 32 +175 36.560 -2.441 18 21 1 6 1 2 4 8 16 32 +176 7.141 24.817 8 13 1 6 1 2 4 8 16 32 +177 -43.170 -30.487 16 15 1 6 1 2 4 8 16 32 +178 -21.228 0.751 4 4 1 6 1 2 4 8 16 32 +179 19.696 10.767 14 10 1 6 1 2 4 8 16 32 +180 -6.494 -29.425 23 19 1 6 1 2 4 8 16 32 +181 54.388 8.630 17 1 1 6 1 2 4 8 16 32 +182 64.203 77.612 7 25 1 6 1 2 4 8 16 32 +183 40.381 1.611 8 3 1 6 1 2 4 8 16 32 +184 -41.711 -5.133 14 21 1 6 1 2 4 8 16 32 +185 74.274 -19.922 22 7 1 6 1 2 4 8 16 32 +186 -73.999 -54.626 7 18 1 6 1 2 4 8 16 32 +187 29.706 15.454 16 3 1 6 1 2 4 8 16 32 +188 23.785 12.177 24 1 1 6 1 2 4 8 16 32 +189 42.578 45.325 15 2 1 6 1 2 4 8 16 32 +190 -16.730 -16.559 15 8 1 6 1 2 4 8 16 32 +191 -14.697 -0.116 5 10 1 6 1 2 4 8 16 32 +192 -19.769 8.392 9 19 1 6 1 2 4 8 16 32 +193 -30.267 14.893 24 17 1 6 1 2 4 8 16 32 +194 -63.116 -67.462 6 19 1 6 1 2 4 8 16 32 +195 86.029 38.916 3 24 1 6 1 2 4 8 16 32 +196 79.480 -24.866 24 24 1 6 1 2 4 8 16 32 +197 35.144 14.734 22 6 1 6 1 2 4 8 16 32 +198 -49.365 -9.052 2 2 1 6 1 2 4 8 16 32 +199 -49.475 -17.578 21 7 1 6 1 2 4 8 16 32 +200 57.501 16.327 17 10 1 6 1 2 4 8 16 32 +201 54.889 12.024 13 13 1 6 1 2 4 8 16 32 +202 -53.027 -33.179 21 20 1 6 1 2 4 8 16 32 +203 -0.415 16.644 3 1 1 6 1 2 4 8 16 32 +204 21.594 16.144 9 17 1 6 1 2 4 8 16 32 +205 -46.924 -49.261 14 17 1 6 1 2 4 8 16 32 +206 18.457 19.733 9 16 1 6 1 2 4 8 16 32 +207 35.822 19.763 3 9 1 6 1 2 4 8 16 32 +208 71.869 29.034 22 25 1 6 1 2 4 8 16 32 +209 -56.378 -42.755 13 1 1 6 1 2 4 8 16 32 +210 -25.800 25.159 10 23 1 6 1 2 4 8 16 32 +211 -5.676 33.850 7 10 1 6 1 2 4 8 16 32 +212 54.041 -5.292 3 15 1 6 1 2 4 8 16 32 +213 -63.074 27.380 11 25 1 6 1 2 4 8 16 32 +214 -16.864 -49.768 17 25 1 6 1 2 4 8 16 32 +215 47.919 13.629 15 16 1 6 1 2 4 8 16 32 +216 -10.724 -2.075 4 1 1 6 1 2 4 8 16 32 +217 -15.067 -23.950 0 0 0 0 +218 38.791 22.443 0 0 0 0 +219 -41.833 -35.361 0 0 0 0 +220 -29.523 -4.843 0 0 0 0 +221 49.725 11.990 0 0 0 0 +222 21.133 14.142 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr09.res b/jsprit-instances/instances/cordeau/pr09.res new file mode 100644 index 00000000..3f0e4ca1 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr09.res @@ -0,0 +1,19 @@ +2153.10 +1 1 411.63 180.00 217 172 123 36 79 58 3 2 103 60 15 117 56 78 59 217 +1 2 248.18 98.00 217 167 30 190 169 13 161 191 216 101 153 29 86 217 +1 3 193.28 178.00 217 67 180 110 47 64 39 23 214 120 105 150 217 +2 1 277.47 178.00 218 5 131 122 109 148 102 84 31 69 182 21 189 156 218 +2 2 414.30 180.00 218 207 197 187 87 176 46 211 92 33 72 25 7 85 128 35 76 118 218 +2 3 73.78 85.00 218 73 16 121 127 108 218 +3 1 206.36 147.00 219 177 135 104 163 199 94 80 52 115 152 149 219 +3 2 333.16 166.00 219 202 11 171 26 12 137 82 186 168 194 88 6 124 209 219 +3 3 328.42 170.00 219 205 162 41 95 77 32 141 14 147 20 130 18 1 143 43 4 219 +4 1 272.14 172.00 220 144 37 98 38 28 66 112 213 99 70 40 100 193 142 192 178 220 +4 2 362.78 171.00 220 184 198 63 45 106 55 129 91 10 159 62 210 220 +4 3 254.11 158.00 220 174 151 140 119 68 158 126 133 139 146 83 157 220 +5 1 359.80 180.00 221 201 165 96 8 17 44 34 185 196 61 22 132 212 114 221 +5 2 225.58 160.00 221 215 170 200 97 181 75 116 71 134 183 145 48 51 221 +5 3 264.70 180.00 221 74 57 208 93 107 195 160 49 50 155 221 +6 1 236.75 153.00 222 65 19 125 203 166 90 27 54 53 111 154 206 204 222 +6 2 266.65 180.00 222 179 138 164 9 81 42 24 173 136 175 89 113 188 222 +6 3 -0.00 0.00 222 222 \ No newline at end of file diff --git a/jsprit-instances/instances/cordeau/pr10 b/jsprit-instances/instances/cordeau/pr10 new file mode 100644 index 00000000..171a8010 --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr10 @@ -0,0 +1,301 @@ +2 4 288 6 +425 170 +425 170 +425 170 +425 170 +425 170 +425 170 + 1 12.805 1.886 15 10 1 6 1 2 4 8 16 32 + 2 18.213 1.373 7 21 1 6 1 2 4 8 16 32 + 3 57.947 -48.779 10 8 1 6 1 2 4 8 16 32 + 4 -52.429 -84.088 20 23 1 6 1 2 4 8 16 32 + 5 60.797 -32.593 11 10 1 6 1 2 4 8 16 32 + 6 23.151 4.205 7 9 1 6 1 2 4 8 16 32 + 7 25.385 22.986 14 21 1 6 1 2 4 8 16 32 + 8 25.513 -52.985 15 16 1 6 1 2 4 8 16 32 + 9 -49.261 -41.718 8 21 1 6 1 2 4 8 16 32 + 10 -37.561 -41.730 5 3 1 6 1 2 4 8 16 32 + 11 -14.520 48.962 17 24 1 6 1 2 4 8 16 32 + 12 41.229 -24.500 1 2 1 6 1 2 4 8 16 32 + 13 -21.863 0.916 3 4 1 6 1 2 4 8 16 32 + 14 -48.181 -16.284 8 18 1 6 1 2 4 8 16 32 + 15 -7.776 44.348 14 5 1 6 1 2 4 8 16 32 + 16 20.801 10.760 3 13 1 6 1 2 4 8 16 32 + 17 -29.712 -46.326 6 13 1 6 1 2 4 8 16 32 + 18 -20.203 -59.564 23 14 1 6 1 2 4 8 16 32 + 19 -87.079 -52.899 14 10 1 6 1 2 4 8 16 32 + 20 3.046 -6.305 1 3 1 6 1 2 4 8 16 32 + 21 11.865 5.261 2 1 1 6 1 2 4 8 16 32 + 22 -24.072 -55.927 17 11 1 6 1 2 4 8 16 32 + 23 -22.803 5.658 15 16 1 6 1 2 4 8 16 32 + 24 -51.904 9.412 18 6 1 6 1 2 4 8 16 32 + 25 12.732 -40.967 15 18 1 6 1 2 4 8 16 32 + 26 -30.988 7.654 7 11 1 6 1 2 4 8 16 32 + 27 37.512 0.458 4 15 1 6 1 2 4 8 16 32 + 28 2.954 -8.563 24 17 1 6 1 2 4 8 16 32 + 29 0.549 3.644 18 17 1 6 1 2 4 8 16 32 + 30 -52.484 9.711 2 1 1 6 1 2 4 8 16 32 + 31 33.936 -48.718 4 1 1 6 1 2 4 8 16 32 + 32 -13.129 -53.601 11 18 1 6 1 2 4 8 16 32 + 33 -99.591 23.303 25 3 1 6 1 2 4 8 16 32 + 34 6.439 -3.516 15 21 1 6 1 2 4 8 16 32 + 35 -14.032 -19.818 18 22 1 6 1 2 4 8 16 32 + 36 -24.677 16.608 9 14 1 6 1 2 4 8 16 32 + 37 -10.260 -81.769 23 4 1 6 1 2 4 8 16 32 + 38 35.858 5.597 22 17 1 6 1 2 4 8 16 32 + 39 -11.603 42.908 9 16 1 6 1 2 4 8 16 32 + 40 -34.662 -15.466 20 8 1 6 1 2 4 8 16 32 + 41 66.852 1.135 13 14 1 6 1 2 4 8 16 32 + 42 6.866 -1.416 3 23 1 6 1 2 4 8 16 32 + 43 1.660 -2.234 6 1 1 6 1 2 4 8 16 32 + 44 37.561 11.450 18 21 1 6 1 2 4 8 16 32 + 45 51.672 -26.343 9 10 1 6 1 2 4 8 16 32 + 46 19.025 -10.889 24 19 1 6 1 2 4 8 16 32 + 47 -37.982 -6.360 19 6 1 6 1 2 4 8 16 32 + 48 -56.537 -42.334 11 4 1 6 1 2 4 8 16 32 + 49 1.099 -14.624 14 18 1 6 1 2 4 8 16 32 + 50 -56.238 -3.076 15 23 1 6 1 2 4 8 16 32 + 51 -23.669 -15.289 5 25 1 6 1 2 4 8 16 32 + 52 -34.277 -1.410 18 17 1 6 1 2 4 8 16 32 + 53 -64.178 63.812 22 11 1 6 1 2 4 8 16 32 + 54 -47.083 -20.386 13 20 1 6 1 2 4 8 16 32 + 55 -33.710 8.380 11 9 1 6 1 2 4 8 16 32 + 56 34.290 26.031 11 23 1 6 1 2 4 8 16 32 + 57 -38.861 42.114 1 14 1 6 1 2 4 8 16 32 + 58 -92.731 44.885 25 7 1 6 1 2 4 8 16 32 + 59 23.633 27.643 19 15 1 6 1 2 4 8 16 32 + 60 -67.139 -67.078 13 22 1 6 1 2 4 8 16 32 + 61 25.726 -25.836 7 4 1 6 1 2 4 8 16 32 + 62 -40.985 -16.895 2 14 1 6 1 2 4 8 16 32 + 63 77.008 -6.097 16 24 1 6 1 2 4 8 16 32 + 64 -54.810 -1.935 2 13 1 6 1 2 4 8 16 32 + 65 -53.943 -29.663 1 9 1 6 1 2 4 8 16 32 + 66 16.089 -27.887 19 3 1 6 1 2 4 8 16 32 + 67 -59.436 36.487 24 23 1 6 1 2 4 8 16 32 + 68 34.473 25.391 19 2 1 6 1 2 4 8 16 32 + 69 -9.283 -6.689 24 23 1 6 1 2 4 8 16 32 + 70 -85.559 -20.477 10 8 1 6 1 2 4 8 16 32 + 71 29.523 18.347 19 23 1 6 1 2 4 8 16 32 + 72 27.814 6.512 1 13 1 6 1 2 4 8 16 32 + 73 42.151 -25.580 19 25 1 6 1 2 4 8 16 32 + 74 82.202 85.828 25 25 1 6 1 2 4 8 16 32 + 75 -47.766 -35.590 24 20 1 6 1 2 4 8 16 32 + 76 22.015 -20.349 11 9 1 6 1 2 4 8 16 32 + 77 -55.756 -33.490 7 15 1 6 1 2 4 8 16 32 + 78 62.006 -1.453 25 4 1 6 1 2 4 8 16 32 + 79 25.549 -3.796 3 1 1 6 1 2 4 8 16 32 + 80 -43.372 -7.379 3 7 1 6 1 2 4 8 16 32 + 81 60.297 52.637 18 12 1 6 1 2 4 8 16 32 + 82 -96.155 34.100 18 5 1 6 1 2 4 8 16 32 + 83 -32.806 -3.845 9 8 1 6 1 2 4 8 16 32 + 84 -47.827 -45.203 21 1 1 6 1 2 4 8 16 32 + 85 -31.128 -93.848 21 24 1 6 1 2 4 8 16 32 + 86 -17.010 -21.857 21 23 1 6 1 2 4 8 16 32 + 87 -8.386 -2.264 11 12 1 6 1 2 4 8 16 32 + 88 35.834 13.147 2 2 1 6 1 2 4 8 16 32 + 89 29.315 54.468 4 22 1 6 1 2 4 8 16 32 + 90 48.352 -8.783 3 3 1 6 1 2 4 8 16 32 + 91 -2.930 27.039 8 12 1 6 1 2 4 8 16 32 + 92 -16.620 -55.389 20 16 1 6 1 2 4 8 16 32 + 93 -40.851 -47.742 23 8 1 6 1 2 4 8 16 32 + 94 -12.878 -2.039 15 25 1 6 1 2 4 8 16 32 + 95 -51.776 7.281 3 6 1 6 1 2 4 8 16 32 + 96 -32.922 23.828 14 24 1 6 1 2 4 8 16 32 + 97 13.983 -34.521 8 16 1 6 1 2 4 8 16 32 + 98 -35.834 -23.834 4 7 1 6 1 2 4 8 16 32 + 99 91.858 5.542 19 9 1 6 1 2 4 8 16 32 +100 -28.442 -34.180 6 23 1 6 1 2 4 8 16 32 +101 33.844 27.875 1 24 1 6 1 2 4 8 16 32 +102 98.431 31.348 2 19 1 6 1 2 4 8 16 32 +103 -57.751 -27.753 3 9 1 6 1 2 4 8 16 32 +104 -43.890 13.007 24 10 1 6 1 2 4 8 16 32 +105 37.585 49.768 6 23 1 6 1 2 4 8 16 32 +106 -3.687 7.373 14 2 1 6 1 2 4 8 16 32 +107 -98.242 61.658 22 5 1 6 1 2 4 8 16 32 +108 -23.560 -32.520 14 25 1 6 1 2 4 8 16 32 +109 22.980 -18.109 7 17 1 6 1 2 4 8 16 32 +110 43.915 -2.985 13 23 1 6 1 2 4 8 16 32 +111 71.509 11.652 19 23 1 6 1 2 4 8 16 32 +112 -43.011 -38.702 6 13 1 6 1 2 4 8 16 32 +113 -83.954 2.179 4 2 1 6 1 2 4 8 16 32 +114 11.090 -40.942 17 24 1 6 1 2 4 8 16 32 +115 27.173 -13.330 17 22 1 6 1 2 4 8 16 32 +116 -86.102 -59.808 13 20 1 6 1 2 4 8 16 32 +117 -22.345 -78.278 21 15 1 6 1 2 4 8 16 32 +118 -38.727 -33.588 8 12 1 6 1 2 4 8 16 32 +119 -1.227 -28.668 7 17 1 6 1 2 4 8 16 32 +120 81.329 -44.244 15 21 1 6 1 2 4 8 16 32 +121 51.904 19.891 5 10 1 6 1 2 4 8 16 32 +122 -34.973 -27.856 6 4 1 6 1 2 4 8 16 32 +123 -51.483 -23.248 17 21 1 6 1 2 4 8 16 32 +124 -0.647 -46.057 4 3 1 6 1 2 4 8 16 32 +125 68.219 -66.986 25 17 1 6 1 2 4 8 16 32 +126 -15.149 -25.482 11 19 1 6 1 2 4 8 16 32 +127 22.412 -34.375 17 10 1 6 1 2 4 8 16 32 +128 36.176 -10.431 17 21 1 6 1 2 4 8 16 32 +129 -23.639 -47.681 2 21 1 6 1 2 4 8 16 32 +130 -14.722 32.684 7 6 1 6 1 2 4 8 16 32 +131 16.821 -12.720 16 8 1 6 1 2 4 8 16 32 +132 93.378 23.004 2 8 1 6 1 2 4 8 16 32 +133 40.344 -24.176 12 13 1 6 1 2 4 8 16 32 +134 5.530 -4.901 7 7 1 6 1 2 4 8 16 32 +135 -78.015 1.270 19 11 1 6 1 2 4 8 16 32 +136 51.569 -45.673 16 18 1 6 1 2 4 8 16 32 +137 49.249 -30.896 17 10 1 6 1 2 4 8 16 32 +138 -62.195 -21.399 8 25 1 6 1 2 4 8 16 32 +139 -5.048 7.306 24 7 1 6 1 2 4 8 16 32 +140 1.727 -70.221 10 17 1 6 1 2 4 8 16 32 +141 1.361 -3.564 20 20 1 6 1 2 4 8 16 32 +142 -15.521 16.425 8 18 1 6 1 2 4 8 16 32 +143 -31.604 -60.938 6 21 1 6 1 2 4 8 16 32 +144 -46.997 -55.560 5 14 1 6 1 2 4 8 16 32 +145 2.301 5.536 23 2 1 6 1 2 4 8 16 32 +146 -30.328 -0.580 14 18 1 6 1 2 4 8 16 32 +147 -16.821 17.664 23 10 1 6 1 2 4 8 16 32 +148 52.655 29.034 13 5 1 6 1 2 4 8 16 32 +149 -11.993 -83.771 12 15 1 6 1 2 4 8 16 32 +150 41.632 43.048 13 17 1 6 1 2 4 8 16 32 +151 8.508 -2.539 20 12 1 6 1 2 4 8 16 32 +152 31.512 -8.978 14 14 1 6 1 2 4 8 16 32 +153 -3.339 -36.243 6 3 1 6 1 2 4 8 16 32 +154 -26.379 13.776 4 7 1 6 1 2 4 8 16 32 +155 28.430 10.571 13 21 1 6 1 2 4 8 16 32 +156 5.975 27.289 1 7 1 6 1 2 4 8 16 32 +157 -32.135 -45.068 9 5 1 6 1 2 4 8 16 32 +158 31.097 -7.916 5 24 1 6 1 2 4 8 16 32 +159 28.198 -29.755 7 13 1 6 1 2 4 8 16 32 +160 -39.612 -33.594 4 18 1 6 1 2 4 8 16 32 +161 -19.220 -5.133 12 19 1 6 1 2 4 8 16 32 +162 -10.114 69.977 20 22 1 6 1 2 4 8 16 32 +163 22.894 -44.348 20 13 1 6 1 2 4 8 16 32 +164 -34.741 0.580 14 10 1 6 1 2 4 8 16 32 +165 -44.952 -77.734 11 4 1 6 1 2 4 8 16 32 +166 -23.749 -56.012 1 17 1 6 1 2 4 8 16 32 +167 69.073 -97.125 5 2 1 6 1 2 4 8 16 32 +168 12.170 -59.869 1 18 1 6 1 2 4 8 16 32 +169 47.339 17.365 14 2 1 6 1 2 4 8 16 32 +170 -4.706 14.056 19 18 1 6 1 2 4 8 16 32 +171 -52.374 -50.244 16 13 1 6 1 2 4 8 16 32 +172 39.215 -29.773 21 24 1 6 1 2 4 8 16 32 +173 -42.316 -60.602 9 25 1 6 1 2 4 8 16 32 +174 19.135 41.150 1 2 1 6 1 2 4 8 16 32 +175 -54.706 -17.596 18 2 1 6 1 2 4 8 16 32 +176 11.737 -83.173 7 7 1 6 1 2 4 8 16 32 +177 -40.582 -53.247 15 23 1 6 1 2 4 8 16 32 +178 -6.421 21.967 21 21 1 6 1 2 4 8 16 32 +179 -31.268 -34.613 4 18 1 6 1 2 4 8 16 32 +180 -3.668 -26.868 21 21 1 6 1 2 4 8 16 32 +181 13.409 -22.302 10 23 1 6 1 2 4 8 16 32 +182 -95.892 -86.322 16 16 1 6 1 2 4 8 16 32 +183 88.983 -53.387 21 22 1 6 1 2 4 8 16 32 +184 -55.048 -32.538 7 11 1 6 1 2 4 8 16 32 +185 27.850 -10.028 8 22 1 6 1 2 4 8 16 32 +186 40.918 -36.090 6 10 1 6 1 2 4 8 16 32 +187 -58.350 15.814 23 15 1 6 1 2 4 8 16 32 +188 -52.161 -74.725 18 23 1 6 1 2 4 8 16 32 +189 -66.772 -34.943 6 7 1 6 1 2 4 8 16 32 +190 -33.374 -62.024 6 1 1 6 1 2 4 8 16 32 +191 -8.649 31.708 14 21 1 6 1 2 4 8 16 32 +192 -26.166 -56.152 14 11 1 6 1 2 4 8 16 32 +193 -39.874 -53.375 22 2 1 6 1 2 4 8 16 32 +194 71.643 -36.981 22 24 1 6 1 2 4 8 16 32 +195 -96.924 8.411 25 25 1 6 1 2 4 8 16 32 +196 -2.911 36.200 13 17 1 6 1 2 4 8 16 32 +197 -53.253 14.099 21 10 1 6 1 2 4 8 16 32 +198 67.316 -39.734 14 18 1 6 1 2 4 8 16 32 +199 -6.525 11.975 18 2 1 6 1 2 4 8 16 32 +200 16.425 33.221 18 12 1 6 1 2 4 8 16 32 +201 -19.061 -56.921 11 4 1 6 1 2 4 8 16 32 +202 25.189 -21.045 10 1 1 6 1 2 4 8 16 32 +203 37.854 -5.524 15 1 1 6 1 2 4 8 16 32 +204 -16.479 48.657 3 6 1 6 1 2 4 8 16 32 +205 2.344 -16.516 2 22 1 6 1 2 4 8 16 32 +206 -48.621 -12.390 12 25 1 6 1 2 4 8 16 32 +207 -42.621 -50.006 18 21 1 6 1 2 4 8 16 32 +208 16.016 11.169 1 18 1 6 1 2 4 8 16 32 +209 -80.408 -60.583 3 14 1 6 1 2 4 8 16 32 +210 -95.068 44.293 4 21 1 6 1 2 4 8 16 32 +211 -6.885 24.884 12 4 1 6 1 2 4 8 16 32 +212 -4.803 21.674 15 1 1 6 1 2 4 8 16 32 +213 7.037 -45.337 22 18 1 6 1 2 4 8 16 32 +214 31.293 -39.905 20 4 1 6 1 2 4 8 16 32 +215 14.984 26.172 16 4 1 6 1 2 4 8 16 32 +216 33.203 -52.289 11 5 1 6 1 2 4 8 16 32 +217 -59.277 39.667 20 15 1 6 1 2 4 8 16 32 +218 30.054 -36.823 13 5 1 6 1 2 4 8 16 32 +219 9.351 -39.044 9 22 1 6 1 2 4 8 16 32 +220 -10.651 54.431 16 21 1 6 1 2 4 8 16 32 +221 20.856 -26.465 7 17 1 6 1 2 4 8 16 32 +222 19.617 17.865 21 8 1 6 1 2 4 8 16 32 +223 -36.981 -92.950 18 4 1 6 1 2 4 8 16 32 +224 -3.760 59.875 4 4 1 6 1 2 4 8 16 32 +225 11.682 -63.336 15 16 1 6 1 2 4 8 16 32 +226 4.468 -36.133 5 5 1 6 1 2 4 8 16 32 +227 47.040 -41.254 24 15 1 6 1 2 4 8 16 32 +228 29.938 -58.710 21 25 1 6 1 2 4 8 16 32 +229 -70.569 -7.037 7 15 1 6 1 2 4 8 16 32 +230 56.262 1.819 24 7 1 6 1 2 4 8 16 32 +231 46.210 -53.522 22 19 1 6 1 2 4 8 16 32 +232 6.366 -14.264 1 11 1 6 1 2 4 8 16 32 +233 -34.540 -39.502 6 13 1 6 1 2 4 8 16 32 +234 -50.537 28.357 4 24 1 6 1 2 4 8 16 32 +235 -61.444 -10.901 14 4 1 6 1 2 4 8 16 32 +236 -30.823 17.902 18 13 1 6 1 2 4 8 16 32 +237 49.658 24.469 16 6 1 6 1 2 4 8 16 32 +238 -69.775 -41.406 1 4 1 6 1 2 4 8 16 32 +239 -18.939 57.690 24 12 1 6 1 2 4 8 16 32 +240 -22.449 15.771 19 4 1 6 1 2 4 8 16 32 +241 -7.599 37.030 19 4 1 6 1 2 4 8 16 32 +242 27.435 17.554 11 25 1 6 1 2 4 8 16 32 +243 45.526 -5.127 9 25 1 6 1 2 4 8 16 32 +244 -33.551 -25.586 3 14 1 6 1 2 4 8 16 32 +245 -4.645 53.754 1 25 1 6 1 2 4 8 16 32 +246 -41.119 -13.361 10 13 1 6 1 2 4 8 16 32 +247 23.010 -45.703 19 13 1 6 1 2 4 8 16 32 +248 17.230 5.096 14 11 1 6 1 2 4 8 16 32 +249 -6.818 -19.873 14 24 1 6 1 2 4 8 16 32 +250 52.966 51.410 24 5 1 6 1 2 4 8 16 32 +251 -28.662 -50.940 16 12 1 6 1 2 4 8 16 32 +252 69.684 -51.520 6 4 1 6 1 2 4 8 16 32 +253 36.884 -17.371 9 5 1 6 1 2 4 8 16 32 +254 -19.659 42.035 20 24 1 6 1 2 4 8 16 32 +255 72.125 65.405 21 17 1 6 1 2 4 8 16 32 +256 -71.368 59.863 8 4 1 6 1 2 4 8 16 32 +257 18.317 -37.750 11 1 1 6 1 2 4 8 16 32 +258 18.121 0.482 13 19 1 6 1 2 4 8 16 32 +259 -1.105 -30.676 24 7 1 6 1 2 4 8 16 32 +260 -44.574 -44.055 15 24 1 6 1 2 4 8 16 32 +261 -28.058 -59.436 6 10 1 6 1 2 4 8 16 32 +262 -7.953 4.639 24 13 1 6 1 2 4 8 16 32 +263 -37.366 -28.528 3 24 1 6 1 2 4 8 16 32 +264 4.388 -38.489 16 3 1 6 1 2 4 8 16 32 +265 -44.592 -35.333 24 14 1 6 1 2 4 8 16 32 +266 -56.714 -39.252 19 2 1 6 1 2 4 8 16 32 +267 13.452 -32.159 5 24 1 6 1 2 4 8 16 32 +268 -20.343 -11.182 11 11 1 6 1 2 4 8 16 32 +269 3.436 -52.734 19 5 1 6 1 2 4 8 16 32 +270 40.576 -54.492 22 14 1 6 1 2 4 8 16 32 +271 31.952 -25.421 23 21 1 6 1 2 4 8 16 32 +272 -57.434 38.525 12 14 1 6 1 2 4 8 16 32 +273 47.510 -42.035 23 15 1 6 1 2 4 8 16 32 +274 -28.143 -41.614 25 3 1 6 1 2 4 8 16 32 +275 -2.258 -5.078 3 15 1 6 1 2 4 8 16 32 +276 -27.167 -27.936 25 15 1 6 1 2 4 8 16 32 +277 -24.048 -47.192 1 21 1 6 1 2 4 8 16 32 +278 -77.521 -55.084 16 17 1 6 1 2 4 8 16 32 +279 -62.036 -43.439 21 18 1 6 1 2 4 8 16 32 +280 -71.936 -20.160 11 15 1 6 1 2 4 8 16 32 +281 -66.504 -39.789 6 19 1 6 1 2 4 8 16 32 +282 14.587 48.444 14 9 1 6 1 2 4 8 16 32 +283 31.366 -29.462 23 10 1 6 1 2 4 8 16 32 +284 6.512 -46.124 9 13 1 6 1 2 4 8 16 32 +285 9.650 39.508 8 25 1 6 1 2 4 8 16 32 +286 16.040 16.681 19 1 1 6 1 2 4 8 16 32 +287 7.745 -75.378 17 11 1 6 1 2 4 8 16 32 +288 -27.173 -4.462 15 25 1 6 1 2 4 8 16 32 +289 -40.198 -12.781 0 0 0 0 +290 -40.488 -35.864 0 0 0 0 +291 -1.193 2.515 0 0 0 0 +292 18.329 -35.468 0 0 0 0 +293 23.746 -0.522 0 0 0 0 +294 -46.396 -39.923 0 0 0 0 diff --git a/jsprit-instances/instances/cordeau/pr10.res b/jsprit-instances/instances/cordeau/pr10.res new file mode 100644 index 00000000..47aec85c --- /dev/null +++ b/jsprit-instances/instances/cordeau/pr10.res @@ -0,0 +1,25 @@ +2921.85 +1 1 217.89 160.00 289 62 14 175 138 280 70 235 50 64 206 246 289 +1 2 424.81 140.00 289 95 30 234 53 256 107 58 210 82 33 195 113 135 229 289 +1 3 351.43 170.00 289 164 55 236 96 57 272 217 67 187 197 24 104 80 289 +1 4 276.62 166.00 289 40 288 13 23 142 147 240 36 154 26 146 52 83 47 289 +2 1 229.12 168.00 290 276 86 35 249 94 161 268 51 122 290 +2 2 220.14 167.00 290 112 93 207 177 193 173 190 143 261 251 17 157 233 290 +2 3 220.30 169.00 290 160 118 274 277 129 32 92 201 18 166 22 192 10 290 +2 4 231.57 163.00 290 179 100 108 126 180 119 259 226 219 264 153 290 +3 1 341.38 164.00 291 145 156 285 282 245 224 162 239 220 15 196 91 212 106 291 +3 2 314.00 166.00 291 139 170 178 211 191 241 39 11 204 254 130 199 262 291 +3 3 196.34 170.00 291 29 42 151 34 134 28 20 141 275 69 87 291 +3 4 258.75 163.00 291 1 21 286 222 16 248 2 258 46 131 232 205 49 43 291 +4 1 335.03 169.00 292 163 214 31 216 270 231 273 227 186 172 73 12 133 253 61 292 +4 2 418.26 169.00 292 218 136 3 252 125 167 183 120 194 198 5 45 137 292 +4 3 212.90 164.00 292 127 159 283 271 202 109 76 221 181 66 267 97 292 +4 4 259.46 170.00 292 25 114 213 284 124 269 168 225 228 8 247 257 292 +5 1 168.08 168.00 293 79 185 115 158 152 128 203 243 110 27 293 +5 2 393.82 170.00 293 6 38 44 169 121 111 102 132 99 63 41 78 230 90 293 +5 3 422.56 170.00 293 208 215 200 174 89 105 150 250 74 255 81 148 237 88 293 +5 4 178.70 167.00 293 242 7 59 101 56 68 71 155 72 293 +6 1 36.13 45.00 294 260 9 294 +6 2 408.90 162.00 294 140 287 176 37 149 117 85 223 4 165 188 144 84 294 +6 3 174.62 164.00 294 75 77 184 65 103 123 54 98 244 263 265 294 +6 4 328.05 166.00 294 266 48 279 281 189 238 278 209 19 116 182 60 171 294 \ No newline at end of file diff --git a/jsprit-instances/instances/lilim/lc1000.txt b/jsprit-instances/instances/lilim/lc1000.txt new file mode 100644 index 00000000..85b0237e --- /dev/null +++ b/jsprit-instances/instances/lilim/lc1000.txt @@ -0,0 +1,13 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 -10 912 967 90 11 0 +2 45 70 -20 825 870 90 6 0 +3 42 66 10 65 146 90 0 75 +4 42 68 -10 727 782 90 9 0 +5 42 65 10 15 67 90 0 7 +6 40 69 20 621 702 90 0 2 +7 40 66 -10 170 225 90 5 0 +8 38 68 20 255 324 90 0 10 +9 38 70 10 534 605 90 0 4 +10 35 66 -20 357 410 90 8 0 +11 35 69 10 448 505 90 0 1 \ No newline at end of file diff --git a/jsprit-instances/instances/lilim/lc101.txt b/jsprit-instances/instances/lilim/lc101.txt new file mode 100644 index 00000000..714b0fba --- /dev/null +++ b/jsprit-instances/instances/lilim/lc101.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 -10 912 967 90 11 0 +2 45 70 -20 825 870 90 6 0 +3 42 66 10 65 146 90 0 75 +4 42 68 -10 727 782 90 9 0 +5 42 65 10 15 67 90 0 7 +6 40 69 20 621 702 90 0 2 +7 40 66 -10 170 225 90 5 0 +8 38 68 20 255 324 90 0 10 +9 38 70 10 534 605 90 0 4 +10 35 66 -20 357 410 90 8 0 +11 35 69 10 448 505 90 0 1 +12 25 85 -20 652 721 90 18 0 +13 22 75 30 30 92 90 0 17 +14 22 85 -40 567 620 90 16 0 +15 20 80 -10 384 429 90 19 0 +16 20 85 40 475 528 90 0 14 +17 18 75 -30 99 148 90 13 0 +18 15 75 20 179 254 90 0 12 +19 15 80 10 278 345 90 0 15 +20 30 50 10 10 73 90 0 24 +21 30 52 -10 914 965 90 30 0 +22 28 52 -20 812 883 90 28 0 +23 28 55 10 732 777 0 0 103 +24 25 50 -10 65 144 90 20 0 +25 25 52 40 169 224 90 0 27 +26 25 55 -10 622 701 90 29 0 +27 23 52 -40 261 316 90 25 0 +28 23 55 20 546 593 90 0 22 +29 20 50 10 358 405 90 0 26 +30 20 55 10 449 504 90 0 21 +31 10 35 -30 200 237 90 32 0 +32 10 40 30 31 100 90 0 31 +33 8 40 40 87 158 90 0 37 +34 8 45 -30 751 816 90 38 0 +35 5 35 10 283 344 90 0 39 +36 5 45 10 665 716 0 0 105 +37 2 40 -40 383 434 90 33 0 +38 0 40 30 479 522 90 0 34 +39 0 45 -10 567 624 90 35 0 +40 35 30 -20 264 321 90 42 0 +41 35 32 -10 166 235 90 43 0 +42 33 32 20 68 149 90 0 40 +43 33 35 10 16 80 90 0 41 +44 32 30 10 359 412 90 0 46 +45 30 30 10 541 600 90 0 48 +46 30 32 -10 448 509 90 44 0 +47 30 35 -10 1054 1127 90 49 0 +48 28 30 -10 632 693 90 45 0 +49 28 35 10 1001 1066 90 0 47 +50 26 32 10 815 880 90 0 52 +51 25 30 10 725 786 0 0 101 +52 25 35 -10 912 969 90 50 0 +53 44 5 20 286 347 90 0 58 +54 42 10 40 186 257 90 0 60 +55 42 15 -40 95 158 90 57 0 +56 40 5 30 385 436 90 0 59 +57 40 15 40 35 87 90 0 55 +58 38 5 -20 471 534 90 53 0 +59 38 15 -30 651 740 90 56 0 +60 35 5 -40 562 629 90 54 0 +61 50 30 -10 531 610 90 67 0 +62 50 35 20 262 317 90 0 68 +63 50 40 50 171 218 90 0 74 +64 48 30 10 632 693 0 0 102 +65 48 40 10 76 129 90 0 72 +66 47 35 10 826 875 90 0 69 +67 47 40 10 12 77 90 0 61 +68 45 30 -20 734 777 90 62 0 +69 45 35 -10 916 969 90 66 0 +70 95 30 -30 387 456 90 81 0 +71 95 35 20 293 360 90 0 77 +72 53 30 -10 450 505 90 65 0 +73 92 30 -10 478 551 90 76 0 +74 53 35 -50 353 412 90 63 0 +75 45 65 -10 997 1068 90 3 0 +76 90 35 10 203 260 90 0 73 +77 88 30 -20 574 643 90 71 0 +78 88 35 20 109 170 0 0 104 +79 87 30 10 668 731 90 0 80 +80 85 25 -10 769 820 90 79 0 +81 85 35 30 47 124 90 0 70 +82 75 55 20 369 420 90 0 85 +83 72 55 -20 265 338 90 87 0 +84 70 58 20 458 523 90 0 89 +85 68 60 -20 555 612 90 82 0 +86 66 55 10 173 238 90 0 91 +87 65 55 20 85 144 90 0 83 +88 65 60 -10 645 708 90 90 0 +89 63 58 -20 737 802 90 84 0 +90 60 55 10 20 84 90 0 88 +91 60 60 -10 836 889 90 86 0 +92 67 85 20 368 441 90 0 93 +93 65 85 -20 475 518 90 92 0 +94 65 82 -10 285 336 90 96 0 +95 62 80 -20 196 239 90 98 0 +96 60 80 10 95 156 90 0 94 +97 60 85 30 561 622 0 0 106 +98 58 75 20 30 84 90 0 95 +99 55 80 -20 743 820 90 100 0 +100 55 85 20 647 726 90 0 99 +101 25 30 -10 725 786 90 51 0 +102 48 30 -10 632 693 90 64 0 +103 28 55 -10 732 777 90 23 0 +104 88 35 -20 109 170 90 78 0 +105 5 45 -10 665 716 90 36 0 +106 60 85 -30 561 622 90 97 0 diff --git a/jsprit-instances/instances/lilim/lc102.txt b/jsprit-instances/instances/lilim/lc102.txt new file mode 100644 index 00000000..5ebfb781 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc102.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 10 0 1127 90 0 75 +2 45 70 -20 0 1125 90 8 0 +3 42 66 10 0 1129 90 0 10 +4 42 68 -20 727 782 90 6 0 +5 42 65 10 0 1130 90 0 9 +6 40 69 20 621 702 90 0 4 +7 40 66 20 0 1130 90 0 11 +8 38 68 20 255 324 90 0 2 +9 38 70 -10 534 605 90 5 0 +10 35 66 -10 357 410 90 3 0 +11 35 69 -20 448 505 90 7 0 +12 25 85 -30 0 1107 90 13 0 +13 22 75 30 30 92 90 0 12 +14 22 85 -40 567 620 90 16 0 +15 20 80 -20 384 429 90 18 0 +16 20 85 40 475 528 90 0 14 +17 18 75 20 99 148 90 0 19 +18 15 75 20 179 254 90 0 15 +19 15 80 -20 278 345 90 17 0 +20 30 50 10 10 73 90 0 22 +21 30 52 -10 0 1135 90 23 0 +22 28 52 -10 812 883 90 20 0 +23 28 55 10 732 777 90 0 21 +24 25 50 10 65 144 90 0 25 +25 25 52 -10 169 224 90 24 0 +26 25 55 -10 0 1130 90 29 0 +27 23 52 10 261 316 90 0 30 +28 23 55 20 546 593 0 0 103 +29 20 50 10 358 405 90 0 26 +30 20 55 -10 449 504 90 27 0 +31 10 35 20 0 1112 90 0 35 +32 10 40 30 31 100 90 0 33 +33 8 40 -30 87 158 90 32 0 +34 8 45 -20 0 1113 90 37 0 +35 5 35 -20 283 344 90 31 0 +36 5 45 -30 665 716 90 38 0 +37 2 40 20 0 1106 90 0 34 +38 0 40 30 479 522 90 0 36 +39 0 45 20 567 624 0 0 104 +40 35 30 -10 264 321 90 43 0 +41 35 32 10 166 235 90 0 51 +42 33 32 20 68 149 90 0 48 +43 33 35 10 16 80 90 0 40 +44 32 30 10 359 412 90 0 47 +45 30 30 -30 541 600 90 46 0 +46 30 32 30 448 509 90 0 45 +47 30 35 -10 1054 1127 90 44 0 +48 28 30 -20 0 1122 90 42 0 +49 28 35 -10 1001 1066 90 52 0 +50 26 32 10 0 1123 0 0 106 +51 25 30 -10 725 786 90 41 0 +52 25 35 10 0 1124 90 0 49 +53 44 5 -10 286 347 90 55 0 +54 42 10 40 186 257 90 0 56 +55 42 15 10 95 158 90 0 53 +56 40 5 -40 385 436 90 54 0 +57 40 15 40 35 87 90 0 60 +58 38 5 30 471 534 90 0 59 +59 38 15 -30 0 1110 90 58 0 +60 35 5 -40 562 629 90 57 0 +61 50 30 -10 531 610 90 67 0 +62 50 35 20 262 317 90 0 66 +63 50 40 50 171 218 90 0 69 +64 48 30 -50 632 693 90 74 0 +65 48 40 10 76 129 90 0 72 +66 47 35 -20 826 875 90 62 0 +67 47 40 10 12 77 90 0 61 +68 45 30 10 734 777 0 0 102 +69 45 35 -50 916 969 90 63 0 +70 95 30 -30 387 456 90 81 0 +71 95 35 20 293 360 90 0 77 +72 53 30 -10 0 1122 90 65 0 +73 92 30 -10 478 551 90 76 0 +74 53 35 50 353 412 90 0 64 +75 45 65 -10 0 1130 90 1 0 +76 90 35 10 203 260 90 0 73 +77 88 30 -20 574 643 90 71 0 +78 88 35 20 109 170 0 0 105 +79 87 30 10 668 731 90 0 80 +80 85 25 -10 769 820 90 79 0 +81 85 35 30 47 124 90 0 70 +82 75 55 20 0 1110 90 0 85 +83 72 55 10 0 1113 90 0 84 +84 70 58 -10 458 523 90 83 0 +85 68 60 -20 0 1116 90 82 0 +86 66 55 -10 173 238 90 90 0 +87 65 55 20 85 144 90 0 89 +88 65 60 30 645 708 90 0 91 +89 63 58 -20 737 802 90 87 0 +90 60 55 10 20 84 90 0 86 +91 60 60 -30 0 1123 90 88 0 +92 67 85 -10 368 441 90 96 0 +93 65 85 40 475 518 90 0 99 +94 65 82 -20 0 1105 90 98 0 +95 62 80 30 0 1108 90 0 100 +96 60 80 10 0 1109 90 0 92 +97 60 85 30 561 622 0 0 101 +98 58 75 20 0 1115 90 0 94 +99 55 80 -40 743 820 90 93 0 +100 55 85 -30 647 726 90 95 0 +101 60 85 -30 561 622 90 97 0 +102 45 30 -10 734 777 90 68 0 +103 23 55 -20 546 593 90 28 0 +104 0 45 -20 567 624 90 39 0 +105 88 35 -20 109 170 90 78 0 +106 26 32 -10 0 1123 90 50 0 diff --git a/jsprit-instances/instances/lilim/lc103.txt b/jsprit-instances/instances/lilim/lc103.txt new file mode 100644 index 00000000..a7dd518f --- /dev/null +++ b/jsprit-instances/instances/lilim/lc103.txt @@ -0,0 +1,106 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 10 0 1127 90 0 75 +2 45 70 -10 0 1125 90 4 0 +3 42 66 10 0 1129 90 0 8 +4 42 68 10 727 782 90 0 2 +5 42 65 10 0 1130 90 0 11 +6 40 69 -10 621 702 90 10 0 +7 40 66 20 0 1130 90 0 9 +8 38 68 -10 255 324 90 3 0 +9 38 70 -20 534 605 90 7 0 +10 35 66 10 357 410 90 0 6 +11 35 69 -10 448 505 90 5 0 +12 25 85 -30 0 1107 90 13 0 +13 22 75 30 30 92 90 0 12 +14 22 85 -40 0 1106 90 15 0 +15 20 80 40 384 429 90 0 14 +16 20 85 -20 0 1105 90 18 0 +17 18 75 20 99 148 90 0 19 +18 15 75 20 0 1110 90 0 16 +19 15 80 -20 0 1106 90 17 0 +20 30 50 10 0 1136 90 0 24 +21 30 52 -20 0 1135 90 22 0 +22 28 52 20 812 883 90 0 21 +23 28 55 -40 732 777 90 25 0 +24 25 50 -10 0 1131 90 20 0 +25 25 52 40 169 224 90 0 23 +26 25 55 10 0 1130 0 0 103 +27 23 52 10 261 316 90 0 30 +28 23 55 -10 0 1128 90 29 0 +29 20 50 10 0 1126 90 0 28 +30 20 55 -10 449 504 90 27 0 +31 10 35 20 0 1112 90 0 38 +32 10 40 30 0 1114 90 0 33 +33 8 40 -30 87 158 90 32 0 +34 8 45 -10 0 1113 90 36 0 +35 5 35 10 283 344 0 0 104 +36 5 45 10 665 716 90 0 34 +37 2 40 20 0 1106 90 0 39 +38 0 40 -20 479 522 90 31 0 +39 0 45 -20 567 624 90 37 0 +40 35 30 10 264 321 90 0 48 +41 35 32 10 166 235 90 0 44 +42 33 32 20 68 149 90 0 49 +43 33 35 10 0 1129 90 0 51 +44 32 30 -10 359 412 90 41 0 +45 30 30 10 541 600 90 0 50 +46 30 32 30 0 1125 0 0 101 +47 30 35 -10 0 1127 90 52 0 +48 28 30 -10 0 1122 90 40 0 +49 28 35 -20 1001 1066 90 42 0 +50 26 32 -10 0 1123 90 45 0 +51 25 30 -10 0 1121 90 43 0 +52 25 35 10 0 1124 90 0 47 +53 44 5 -40 286 347 90 57 0 +54 42 10 40 0 1105 90 0 56 +55 42 15 10 95 158 90 0 59 +56 40 5 -40 385 436 90 54 0 +57 40 15 40 0 1111 90 0 53 +58 38 5 30 471 534 90 0 60 +59 38 15 -10 0 1110 90 55 0 +60 35 5 -30 0 1100 90 58 0 +61 50 30 10 0 1123 90 0 66 +62 50 35 20 262 317 90 0 74 +63 50 40 -10 0 1131 90 79 0 +64 48 30 10 632 693 90 0 69 +65 48 40 -10 76 129 90 67 0 +66 47 35 -10 826 875 90 61 0 +67 47 40 10 12 77 90 0 65 +68 45 30 -10 734 777 90 72 0 +69 45 35 -10 916 969 90 64 0 +70 95 30 30 387 456 90 0 80 +71 95 35 20 0 1088 90 0 73 +72 53 30 10 0 1122 90 0 68 +73 92 30 -20 0 1090 90 71 0 +74 53 35 -20 353 412 90 62 0 +75 45 65 -10 0 1130 90 1 0 +76 90 35 10 203 260 90 0 77 +77 88 30 -10 574 643 90 76 0 +78 88 35 -30 109 170 90 81 0 +79 87 30 10 668 731 90 0 63 +80 85 25 -30 769 820 90 70 0 +81 85 35 30 0 1098 90 0 78 +82 75 55 -10 0 1110 90 83 0 +83 72 55 10 0 1113 90 0 82 +84 70 58 -10 458 523 90 90 0 +85 68 60 30 0 1116 90 0 91 +86 66 55 10 0 1119 90 0 89 +87 65 55 20 85 144 90 0 88 +88 65 60 -20 645 708 90 87 0 +89 63 58 -10 0 1121 90 86 0 +90 60 55 10 0 1125 90 0 84 +91 60 60 -30 0 1123 90 85 0 +92 67 85 -20 368 441 90 98 0 +93 65 85 40 475 518 0 0 102 +94 65 82 10 0 1105 90 0 99 +95 62 80 -10 0 1108 90 96 0 +96 60 80 10 0 1109 90 0 95 +97 60 85 30 0 1105 90 0 100 +98 58 75 20 0 1115 90 0 92 +99 55 80 -10 743 820 90 94 0 +100 55 85 -30 647 726 90 97 0 +101 30 32 -30 0 1125 90 46 0 +102 65 85 -40 475 518 90 93 0 +103 25 55 -10 0 1130 90 26 0 +104 5 35 -10 283 344 90 35 0 diff --git a/jsprit-instances/instances/lilim/lc104.txt b/jsprit-instances/instances/lilim/lc104.txt new file mode 100644 index 00000000..8e14b79b --- /dev/null +++ b/jsprit-instances/instances/lilim/lc104.txt @@ -0,0 +1,108 @@ +25 200 0 +0 40 50 0 0 1236 0 0 0 +1 45 68 -30 0 1127 90 2 0 +2 45 70 30 0 1125 90 0 1 +3 42 66 10 0 1129 90 0 8 +4 42 68 -20 727 782 90 7 0 +5 42 65 10 0 1130 90 0 9 +6 40 69 -10 0 1127 90 11 0 +7 40 66 20 0 1130 90 0 4 +8 38 68 -10 255 324 90 3 0 +9 38 70 -10 534 605 90 5 0 +10 35 66 -20 0 1129 90 12 0 +11 35 69 10 448 505 90 0 6 +12 25 85 20 0 1107 90 0 10 +13 22 75 30 30 92 90 0 16 +14 22 85 10 0 1106 0 0 102 +15 20 80 -10 384 429 90 19 0 +16 20 85 -30 0 1105 90 13 0 +17 18 75 20 0 1112 90 0 18 +18 15 75 -20 0 1110 90 17 0 +19 15 80 10 0 1106 90 0 15 +20 30 50 10 0 1136 90 0 25 +21 30 52 -10 0 1135 90 30 0 +22 28 52 -10 0 1133 90 26 0 +23 28 55 -20 732 777 90 28 0 +24 25 50 10 0 1131 0 0 101 +25 25 52 -10 169 224 90 20 0 +26 25 55 10 0 1130 90 0 22 +27 23 52 10 0 1128 90 0 29 +28 23 55 20 0 1128 90 0 23 +29 20 50 -10 0 1126 90 27 0 +30 20 55 10 0 1125 90 0 21 +31 10 35 20 0 1112 90 0 38 +32 10 40 30 0 1114 90 0 37 +33 8 40 40 0 1112 0 0 103 +34 8 45 -10 0 1113 90 36 0 +35 5 35 10 0 1107 90 0 39 +36 5 45 10 0 1110 90 0 34 +37 2 40 -30 0 1106 90 32 0 +38 0 40 -20 479 522 90 31 0 +39 0 45 -10 0 1105 90 35 0 +40 35 30 10 0 1125 90 0 46 +41 35 32 -10 0 1127 90 43 0 +42 33 32 20 0 1126 90 0 52 +43 33 35 10 0 1129 90 0 41 +44 32 30 10 359 412 90 0 48 +45 30 30 10 0 1123 90 0 51 +46 30 32 -10 0 1125 90 40 0 +47 30 35 10 0 1127 0 0 105 +48 28 30 -10 0 1122 90 44 0 +49 28 35 -10 0 1126 90 50 0 +50 26 32 10 0 1123 90 0 49 +51 25 30 -10 0 1121 90 45 0 +52 25 35 -20 0 1124 90 42 0 +53 44 5 20 286 347 90 0 59 +54 42 10 -10 0 1105 90 55 0 +55 42 15 10 95 158 90 0 54 +56 40 5 -40 0 1101 90 57 0 +57 40 15 40 0 1111 90 0 56 +58 38 5 30 471 534 90 0 60 +59 38 15 -20 0 1110 90 53 0 +60 35 5 -30 0 1100 90 58 0 +61 50 30 10 0 1123 90 0 66 +62 50 35 20 262 317 90 0 69 +63 50 40 -10 0 1131 90 80 0 +64 48 30 -10 0 1124 90 72 0 +65 48 40 10 0 1133 90 0 74 +66 47 35 -10 0 1129 90 61 0 +67 47 40 10 12 77 90 0 68 +68 45 30 -10 0 1125 90 67 0 +69 45 35 -20 916 969 90 62 0 +70 95 30 -20 0 1087 90 78 0 +71 95 35 -30 0 1088 90 81 0 +72 53 30 10 0 1122 90 0 64 +73 92 30 -10 0 1090 90 76 0 +74 53 35 -10 353 412 90 65 0 +75 45 65 20 0 1130 0 0 106 +76 90 35 10 203 260 90 0 73 +77 88 30 10 574 643 90 0 79 +78 88 35 20 0 1095 90 0 70 +79 87 30 -10 668 731 90 77 0 +80 85 25 10 0 1094 90 0 63 +81 85 35 30 0 1098 90 0 71 +82 75 55 20 0 1110 90 0 84 +83 72 55 10 0 1113 90 0 88 +84 70 58 -20 458 523 90 82 0 +85 68 60 30 0 1116 90 0 89 +86 66 55 10 0 1119 90 0 91 +87 65 55 -10 85 144 90 90 0 +88 65 60 -10 0 1119 90 83 0 +89 63 58 -30 0 1121 90 85 0 +90 60 55 10 0 1125 90 0 87 +91 60 60 -10 0 1123 90 86 0 +92 67 85 20 368 441 0 0 104 +93 65 85 -30 0 1102 90 95 0 +94 65 82 10 0 1105 90 0 99 +95 62 80 30 0 1108 90 0 93 +96 60 80 -20 0 1109 90 98 0 +97 60 85 30 0 1105 90 0 100 +98 58 75 20 0 1115 90 0 96 +99 55 80 -10 743 820 90 94 0 +100 55 85 -30 647 726 90 97 0 +101 25 50 -10 0 1131 90 24 0 +102 22 85 -10 0 1106 90 14 0 +103 8 40 -40 0 1112 90 33 0 +104 67 85 -20 368 441 90 92 0 +105 30 35 -10 0 1127 90 47 0 +106 45 65 -20 0 1130 90 75 0 diff --git a/jsprit-instances/instances/lilim/lc105.txt b/jsprit-instances/instances/lilim/lc105.txt new file mode 100644 index 00000000..a187d143 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc105.txt @@ -0,0 +1,108 @@ +25 200 0 +0 40 50 0 0 1236 0 0 0 +1 45 68 10 885 994 90 0 75 +2 45 70 -20 802 893 90 6 0 +3 42 66 -10 25 186 90 5 0 +4 42 68 -20 699 810 90 8 0 +5 42 65 10 15 120 90 0 3 +6 40 69 20 580 743 90 0 2 +7 40 66 20 142 253 90 0 9 +8 38 68 20 220 359 90 0 4 +9 38 70 -20 499 640 90 7 0 +10 35 66 10 331 436 90 0 11 +11 35 69 -10 420 533 90 10 0 +12 25 85 -20 617 756 90 17 0 +13 22 75 30 30 155 90 0 18 +14 22 85 -40 541 646 90 16 0 +15 20 80 -10 362 451 90 19 0 +16 20 85 40 448 555 90 0 14 +17 18 75 20 75 172 90 0 12 +18 15 75 -30 142 291 90 13 0 +19 15 80 10 244 379 90 0 15 +20 30 50 10 10 137 90 0 24 +21 30 52 -10 888 991 90 26 0 +22 28 52 -20 776 919 90 28 0 +23 28 55 10 709 800 0 0 106 +24 25 50 -10 25 184 90 20 0 +25 25 52 40 142 251 90 0 27 +26 25 55 10 582 741 90 0 21 +27 23 52 -40 234 343 90 25 0 +28 23 55 20 523 616 90 0 22 +29 20 50 10 335 428 90 0 30 +30 20 55 -10 422 531 90 29 0 +31 10 35 20 181 256 90 0 35 +32 10 40 30 31 170 90 0 36 +33 8 40 40 52 193 90 0 38 +34 8 45 20 719 848 0 0 101 +35 5 35 -20 252 375 90 31 0 +36 5 45 -30 639 742 90 32 0 +37 2 40 20 357 460 90 0 39 +38 0 40 -40 457 544 90 33 0 +39 0 45 -20 538 653 90 37 0 +40 35 30 -10 236 349 90 41 0 +41 35 32 10 132 269 90 0 40 +42 33 32 20 27 190 90 0 48 +43 33 35 10 16 144 90 0 44 +44 32 30 -10 332 439 90 43 0 +45 30 30 -30 512 629 90 46 0 +46 30 32 30 417 540 90 0 45 +47 30 35 -10 982 1127 90 49 0 +48 28 30 -20 601 724 90 42 0 +49 28 35 10 969 1098 90 0 47 +50 26 32 -10 783 912 90 51 0 +51 25 30 10 695 816 90 0 50 +52 25 35 10 883 998 0 0 104 +53 44 5 -40 255 378 90 54 0 +54 42 10 40 150 293 90 0 53 +55 42 15 10 63 190 90 0 58 +56 40 5 -40 359 462 90 57 0 +57 40 15 40 35 140 90 0 56 +58 38 5 -10 439 566 90 55 0 +59 38 15 -20 607 784 90 60 0 +60 35 5 20 529 662 90 0 59 +61 50 30 10 491 650 90 0 68 +62 50 35 20 235 344 90 0 69 +63 50 40 50 147 242 90 0 72 +64 48 30 -10 601 724 90 67 0 +65 48 40 10 50 155 0 0 103 +66 47 35 -50 802 899 90 74 0 +67 47 40 10 12 143 90 0 64 +68 45 30 -10 712 799 90 61 0 +69 45 35 -20 889 996 90 62 0 +70 95 30 -30 353 490 90 81 0 +71 95 35 20 260 393 90 0 73 +72 53 30 -50 422 533 90 63 0 +73 92 30 -20 442 587 90 71 0 +74 53 35 50 323 442 90 0 66 +75 45 65 -10 962 1103 90 1 0 +76 90 35 -20 175 288 90 78 0 +77 88 30 10 539 678 90 0 80 +78 88 35 20 78 201 90 0 76 +79 87 30 10 636 763 0 0 102 +80 85 25 -10 744 845 90 77 0 +81 85 35 30 47 201 90 0 70 +82 75 55 20 344 445 90 0 88 +83 72 55 10 228 375 90 0 84 +84 70 58 -10 425 556 90 83 0 +85 68 60 -10 527 640 90 90 0 +86 66 55 10 141 270 90 0 91 +87 65 55 20 56 173 90 0 89 +88 65 60 -20 614 739 90 82 0 +89 63 58 -20 705 834 90 87 0 +90 60 55 10 20 148 90 0 85 +91 60 60 -10 809 916 90 86 0 +92 67 85 -10 331 478 90 96 0 +93 65 85 40 453 540 90 0 97 +94 65 82 10 260 361 90 0 100 +95 62 80 -20 174 261 90 98 0 +96 60 80 10 64 187 90 0 92 +97 60 85 -40 531 652 90 93 0 +98 58 75 20 30 139 90 0 95 +99 55 80 10 705 858 0 0 105 +100 55 85 -10 608 765 90 94 0 +101 8 45 -20 719 848 90 34 0 +102 87 30 -10 636 763 90 79 0 +103 48 40 -10 50 155 90 65 0 +104 25 35 -10 883 998 90 52 0 +105 55 80 -10 705 858 90 99 0 +106 28 55 -10 709 800 90 23 0 diff --git a/jsprit-instances/instances/lilim/lc106.txt b/jsprit-instances/instances/lilim/lc106.txt new file mode 100644 index 00000000..41b717fb --- /dev/null +++ b/jsprit-instances/instances/lilim/lc106.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 -20 890 989 90 6 0 +2 45 70 -10 816 879 90 9 0 +3 42 66 10 55 156 90 0 75 +4 42 68 -20 703 806 90 8 0 +5 42 65 10 15 60 90 0 10 +6 40 69 20 559 764 90 0 1 +7 40 66 20 172 223 90 0 11 +8 38 68 20 250 329 90 0 4 +9 38 70 10 489 650 90 0 2 +10 35 66 -10 361 406 90 5 0 +11 35 69 -20 450 503 90 7 0 +12 25 85 -40 647 726 90 16 0 +13 22 75 30 30 95 90 0 17 +14 22 85 -20 571 616 90 18 0 +15 20 80 -10 392 421 90 19 0 +16 20 85 40 478 525 90 0 12 +17 18 75 -30 105 142 90 13 0 +18 15 75 20 172 261 90 0 14 +19 15 80 10 274 349 90 0 15 +20 30 50 10 10 77 90 0 25 +21 30 52 -10 918 961 90 26 0 +22 28 52 20 806 889 0 0 105 +23 28 55 -10 739 770 90 24 0 +24 25 50 10 55 154 90 0 23 +25 25 52 -10 172 221 90 20 0 +26 25 55 10 612 711 90 0 21 +27 23 52 10 264 313 90 0 29 +28 23 55 -10 553 586 90 30 0 +29 20 50 -10 365 398 90 27 0 +30 20 55 10 452 501 90 0 28 +31 10 35 20 204 233 90 0 34 +32 10 40 30 31 189 90 0 35 +33 8 40 40 42 203 90 0 37 +34 8 45 -20 715 852 90 31 0 +35 5 35 -30 251 376 90 32 0 +36 5 45 10 648 733 0 0 102 +37 2 40 -40 365 452 90 33 0 +38 0 40 30 474 527 90 0 39 +39 0 45 -30 541 650 90 38 0 +40 35 30 10 240 345 90 0 52 +41 35 32 10 123 278 90 0 47 +42 33 32 20 19 225 90 0 46 +43 33 35 10 16 153 90 0 48 +44 32 30 10 338 433 90 0 51 +45 30 30 10 513 628 90 0 49 +46 30 32 -20 415 542 90 42 0 +47 30 35 -10 872 1127 90 41 0 +48 28 30 -10 599 726 90 43 0 +49 28 35 -10 917 1126 90 45 0 +50 26 32 10 779 916 0 0 101 +51 25 30 -10 695 816 90 44 0 +52 25 35 -10 857 1024 90 40 0 +53 44 5 20 221 412 90 0 56 +54 42 10 40 96 347 90 0 59 +55 42 15 -40 35 233 90 57 0 +56 40 5 -20 347 474 90 53 0 +57 40 15 40 35 172 90 0 55 +58 38 5 30 403 602 90 0 60 +59 38 15 -40 521 870 90 54 0 +60 35 5 -30 487 704 90 58 0 +61 50 30 10 422 719 90 0 69 +62 50 35 -10 217 362 90 67 0 +63 50 40 50 142 247 90 0 64 +64 48 30 -50 567 758 90 63 0 +65 48 40 10 34 171 90 0 74 +66 47 35 10 794 907 0 0 103 +67 47 40 10 12 226 90 0 62 +68 45 30 -10 716 795 90 72 0 +69 45 35 -10 873 1012 90 61 0 +70 95 30 30 266 577 90 0 73 +71 95 35 -20 181 472 90 78 0 +72 53 30 10 402 553 90 0 68 +73 92 30 -30 345 684 90 70 0 +74 53 35 -10 294 471 90 65 0 +75 45 65 -10 951 1114 90 3 0 +76 90 35 10 153 310 90 0 79 +77 88 30 10 450 767 90 0 80 +78 88 35 20 50 237 90 0 71 +79 87 30 -10 567 832 90 76 0 +80 85 25 -10 713 876 90 77 0 +81 85 35 30 47 331 0 0 104 +82 75 55 20 311 478 90 0 91 +83 72 55 10 127 476 90 0 89 +84 70 58 -10 349 632 90 86 0 +85 68 60 30 476 691 90 0 88 +86 66 55 10 67 344 90 0 84 +87 65 55 -10 25 256 90 90 0 +88 65 60 -30 546 807 90 85 0 +89 63 58 -10 630 909 90 83 0 +90 60 55 10 20 293 90 0 87 +91 60 60 -20 769 956 90 82 0 +92 67 85 -10 229 580 90 96 0 +93 65 85 -10 442 551 90 94 0 +94 65 82 10 227 394 90 0 93 +95 62 80 30 163 272 90 0 99 +96 60 80 10 36 291 90 0 92 +97 60 85 -20 469 714 90 98 0 +98 58 75 20 30 227 90 0 97 +99 55 80 -30 595 968 90 95 0 +100 55 85 20 493 880 0 0 106 +101 26 32 -10 779 916 90 50 0 +102 5 45 -10 648 733 90 36 0 +103 47 35 -10 794 907 90 66 0 +104 85 35 -30 47 331 90 81 0 +105 28 52 -20 806 889 90 22 0 +106 55 85 -20 493 880 90 100 0 diff --git a/jsprit-instances/instances/lilim/lc107.txt b/jsprit-instances/instances/lilim/lc107.txt new file mode 100644 index 00000000..530a38f6 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc107.txt @@ -0,0 +1,108 @@ +25 200 0 +0 40 50 0 0 1236 0 0 0 +1 45 68 10 850 1030 90 0 75 +2 45 70 -20 758 938 90 8 0 +3 42 66 10 16 196 90 0 10 +4 42 68 -20 665 845 90 6 0 +5 42 65 10 15 195 90 0 9 +6 40 69 20 572 752 90 0 4 +7 40 66 20 108 288 90 0 11 +8 38 68 20 200 380 90 0 2 +9 38 70 -10 480 660 90 5 0 +10 35 66 -10 294 474 90 3 0 +11 35 69 -20 387 567 90 7 0 +12 25 85 -40 597 777 90 16 0 +13 22 75 30 30 210 90 0 14 +14 22 85 -30 504 684 90 13 0 +15 20 80 -10 317 497 90 19 0 +16 20 85 40 412 592 90 0 12 +17 18 75 20 34 214 90 0 18 +18 15 75 -20 127 307 90 17 0 +19 15 80 10 222 402 90 0 15 +20 30 50 10 10 190 90 0 30 +21 30 52 -20 850 1030 90 28 0 +22 28 52 -10 758 938 90 26 0 +23 28 55 10 665 845 0 0 102 +24 25 50 10 15 195 90 0 25 +25 25 52 -10 107 287 90 24 0 +26 25 55 10 572 752 90 0 22 +27 23 52 10 199 379 90 0 29 +28 23 55 20 480 660 90 0 21 +29 20 50 -10 292 472 90 27 0 +30 20 55 -10 387 567 90 20 0 +31 10 35 -30 129 309 90 32 0 +32 10 40 30 31 211 90 0 31 +33 8 40 40 33 213 90 0 36 +34 8 45 -30 694 874 90 38 0 +35 5 35 10 224 404 90 0 37 +36 5 45 -40 601 781 90 33 0 +37 2 40 -10 319 499 90 35 0 +38 0 40 30 411 591 90 0 34 +39 0 45 20 506 686 0 0 101 +40 35 30 -20 203 383 90 42 0 +41 35 32 10 111 291 90 0 51 +42 33 32 20 19 199 90 0 40 +43 33 35 10 16 196 90 0 48 +44 32 30 10 296 476 90 0 46 +45 30 30 10 481 661 90 0 52 +46 30 32 -10 389 569 90 44 0 +47 30 35 10 947 1127 0 0 105 +48 28 30 -10 573 753 90 43 0 +49 28 35 -10 944 1124 90 50 0 +50 26 32 10 758 938 90 0 49 +51 25 30 -10 666 846 90 41 0 +52 25 35 -10 851 1031 90 45 0 +53 44 5 -10 227 407 90 55 0 +54 42 10 40 132 312 90 0 56 +55 42 15 10 37 217 90 0 53 +56 40 5 -40 321 501 90 54 0 +57 40 15 40 35 215 90 0 60 +58 38 5 30 413 593 90 0 59 +59 38 15 -30 606 786 90 58 0 +60 35 5 -40 506 686 90 57 0 +61 50 30 10 481 661 0 0 103 +62 50 35 -10 200 380 90 65 0 +63 50 40 50 105 285 90 0 66 +64 48 30 -50 573 753 90 74 0 +65 48 40 10 13 193 90 0 62 +66 47 35 -50 761 941 90 63 0 +67 47 40 10 12 192 90 0 69 +68 45 30 -10 666 846 90 72 0 +69 45 35 -10 853 1033 90 67 0 +70 95 30 30 332 512 90 0 73 +71 95 35 -20 237 417 90 78 0 +72 53 30 10 388 568 90 0 68 +73 92 30 -30 425 605 90 70 0 +74 53 35 50 293 473 90 0 64 +75 45 65 -10 943 1123 90 1 0 +76 90 35 10 142 322 90 0 79 +77 88 30 10 519 699 90 0 80 +78 88 35 20 50 230 90 0 71 +79 87 30 -10 610 790 90 76 0 +80 85 25 -10 705 885 90 77 0 +81 85 35 30 47 227 0 0 104 +82 75 55 -20 305 485 90 87 0 +83 72 55 -10 212 392 90 90 0 +84 70 58 20 401 581 90 0 89 +85 68 60 30 494 674 90 0 91 +86 66 55 10 116 296 90 0 88 +87 65 55 20 25 205 90 0 82 +88 65 60 -10 587 767 90 86 0 +89 63 58 -20 680 860 90 84 0 +90 60 55 10 20 200 90 0 83 +91 60 60 -30 773 953 90 85 0 +92 67 85 -10 315 495 90 94 0 +93 65 85 -20 407 587 90 98 0 +94 65 82 10 221 401 90 0 92 +95 62 80 30 128 308 90 0 99 +96 60 80 10 36 216 90 0 97 +97 60 85 -10 502 682 90 96 0 +98 58 75 20 30 210 90 0 93 +99 55 80 -30 692 872 90 95 0 +100 55 85 20 597 777 0 0 106 +101 0 45 -20 506 686 90 39 0 +102 28 55 -10 665 845 90 23 0 +103 50 30 -10 481 661 90 61 0 +104 85 35 -30 47 227 90 81 0 +105 30 35 -10 947 1127 90 47 0 +106 55 85 -20 597 777 90 100 0 diff --git a/jsprit-instances/instances/lilim/lc108.txt b/jsprit-instances/instances/lilim/lc108.txt new file mode 100644 index 00000000..512dc88f --- /dev/null +++ b/jsprit-instances/instances/lilim/lc108.txt @@ -0,0 +1,108 @@ +25 200 0 +0 40 50 0 0 1236 0 0 0 +1 45 68 -10 830 1049 90 5 0 +2 45 70 30 756 939 90 0 75 +3 42 66 10 16 336 90 0 10 +4 42 68 -20 643 866 90 6 0 +5 42 65 10 15 226 90 0 1 +6 40 69 20 499 824 90 0 4 +7 40 66 20 87 308 90 0 8 +8 38 68 -20 150 429 90 7 0 +9 38 70 -10 429 710 90 11 0 +10 35 66 -10 279 488 90 3 0 +11 35 69 10 363 590 90 0 9 +12 25 85 -40 547 826 90 15 0 +13 22 75 30 30 280 90 0 17 +14 22 85 -20 489 698 90 18 0 +15 20 80 40 318 495 90 0 12 +16 20 85 -10 394 609 90 19 0 +17 18 75 -30 33 226 90 13 0 +18 15 75 20 68 365 90 0 14 +19 15 80 10 176 447 90 0 16 +20 30 50 10 10 265 90 0 22 +21 30 52 -20 836 1043 90 28 0 +22 28 52 -10 704 991 90 20 0 +23 28 55 -10 664 845 90 26 0 +24 25 50 10 15 333 90 0 29 +25 25 52 40 88 305 90 0 30 +26 25 55 10 502 821 90 0 23 +27 23 52 10 179 398 0 0 106 +28 23 55 20 476 663 90 0 21 +29 20 50 -10 288 475 90 24 0 +30 20 55 -40 368 585 90 25 0 +31 10 35 20 144 293 90 0 35 +32 10 40 30 31 309 90 0 34 +33 8 40 40 33 313 90 0 37 +34 8 45 -30 655 912 90 32 0 +35 5 35 -20 191 436 90 31 0 +36 5 45 -30 588 793 90 38 0 +37 2 40 -40 305 512 90 33 0 +38 0 40 30 414 587 90 0 36 +39 0 45 20 481 710 0 0 104 +40 35 30 10 180 405 90 0 47 +41 35 32 10 63 338 90 0 45 +42 33 32 20 19 345 90 0 44 +43 33 35 10 16 273 90 0 52 +44 32 30 -20 278 493 90 42 0 +45 30 30 -10 453 688 90 41 0 +46 30 32 30 355 602 90 0 48 +47 30 35 -10 837 1127 90 40 0 +48 28 30 -30 539 786 90 46 0 +49 28 35 10 867 1126 0 0 105 +50 26 32 -10 719 976 90 51 0 +51 25 30 10 635 876 90 0 50 +52 25 35 -10 825 1056 90 43 0 +53 44 5 20 193 440 90 0 56 +54 42 10 40 78 365 90 0 58 +55 42 15 -40 35 287 90 57 0 +56 40 5 -20 308 513 90 53 0 +57 40 15 40 35 246 90 0 55 +58 38 5 -40 376 629 90 54 0 +59 38 15 -20 519 872 90 60 0 +60 35 5 20 463 728 90 0 59 +61 50 30 -10 412 729 90 67 0 +62 50 35 20 181 398 90 0 66 +63 50 40 50 100 289 90 0 69 +64 48 30 -50 539 786 90 74 0 +65 48 40 10 12 223 90 0 72 +66 47 35 -20 753 948 90 62 0 +67 47 40 10 12 275 90 0 61 +68 45 30 10 669 842 0 0 102 +69 45 35 -50 836 1049 90 63 0 +70 95 30 -20 284 559 90 78 0 +71 95 35 -30 194 459 90 81 0 +72 53 30 -10 367 588 90 65 0 +73 92 30 10 370 659 90 0 77 +74 53 35 50 263 502 90 0 64 +75 45 65 -30 847 1130 90 2 0 +76 90 35 10 119 344 90 0 80 +77 88 30 -10 469 748 90 73 0 +78 88 35 20 50 295 90 0 70 +79 87 30 10 573 826 0 0 103 +80 85 25 -10 694 895 90 76 0 +81 85 35 30 47 356 90 0 71 +82 75 55 20 293 496 90 0 85 +83 72 55 -20 154 449 90 87 0 +84 70 58 20 360 621 90 0 89 +85 68 60 -20 470 697 90 82 0 +86 66 55 10 76 335 90 0 91 +87 65 55 20 25 260 90 0 83 +88 65 60 -10 551 802 90 90 0 +89 63 58 -20 640 899 90 84 0 +90 60 55 10 20 276 90 0 88 +91 60 60 -10 756 969 90 86 0 +92 67 85 -10 257 552 90 96 0 +93 65 85 40 409 584 90 0 99 +94 65 82 -20 209 412 90 98 0 +95 62 80 30 130 305 90 0 100 +96 60 80 10 36 283 90 0 92 +97 60 85 30 470 713 0 0 101 +98 58 75 20 30 248 90 0 94 +99 55 80 -40 628 935 90 93 0 +100 55 85 -30 530 843 90 95 0 +101 60 85 -30 470 713 90 97 0 +102 45 30 -10 669 842 90 68 0 +103 87 30 -10 573 826 90 79 0 +104 0 45 -20 481 710 90 39 0 +105 28 35 -10 867 1126 90 49 0 +106 23 52 -10 179 398 90 27 0 diff --git a/jsprit-instances/instances/lilim/lc109.txt b/jsprit-instances/instances/lilim/lc109.txt new file mode 100644 index 00000000..fa49f304 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc109.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 10 760 1120 90 0 75 +2 45 70 -10 668 1028 90 9 0 +3 42 66 -10 16 376 90 5 0 +4 42 68 -20 575 935 90 7 0 +5 42 65 10 15 375 90 0 3 +6 40 69 -10 482 842 90 11 0 +7 40 66 20 18 378 90 0 4 +8 38 68 20 110 470 90 0 10 +9 38 70 10 390 750 90 0 2 +10 35 66 -20 204 564 90 8 0 +11 35 69 10 297 657 90 0 6 +12 25 85 -10 507 867 90 19 0 +13 22 75 30 30 390 90 0 14 +14 22 85 -30 414 774 90 13 0 +15 20 80 -20 227 587 90 17 0 +16 20 85 -20 322 682 90 18 0 +17 18 75 20 33 393 90 0 15 +18 15 75 20 37 397 90 0 16 +19 15 80 10 132 492 90 0 12 +20 30 50 10 10 370 90 0 24 +21 30 52 -10 760 1120 90 23 0 +22 28 52 -20 668 1028 90 28 0 +23 28 55 10 575 935 90 0 21 +24 25 50 -10 15 375 90 20 0 +25 25 52 40 17 377 90 0 30 +26 25 55 -10 482 842 90 29 0 +27 23 52 10 109 469 0 0 105 +28 23 55 20 390 750 90 0 22 +29 20 50 10 202 562 90 0 26 +30 20 55 -40 297 657 90 25 0 +31 10 35 -40 39 399 90 33 0 +32 10 40 30 31 391 90 0 37 +33 8 40 40 33 393 90 0 31 +34 8 45 -30 604 964 90 38 0 +35 5 35 10 134 494 90 0 39 +36 5 45 10 511 871 0 0 103 +37 2 40 -30 229 589 90 32 0 +38 0 40 30 321 681 90 0 34 +39 0 45 -10 416 776 90 35 0 +40 35 30 -10 113 473 90 41 0 +41 35 32 10 21 381 90 0 40 +42 33 32 -10 19 379 90 43 0 +43 33 35 10 16 376 90 0 42 +44 32 30 10 206 566 90 0 45 +45 30 30 -10 391 751 90 44 0 +46 30 32 30 299 659 90 0 51 +47 30 35 -10 767 1127 90 50 0 +48 28 30 10 483 843 0 0 106 +49 28 35 -10 766 1126 90 52 0 +50 26 32 10 668 1028 90 0 47 +51 25 30 -30 576 936 90 46 0 +52 25 35 10 761 1121 90 0 49 +53 44 5 20 137 497 90 0 58 +54 42 10 40 42 402 90 0 56 +55 42 15 -40 35 395 90 57 0 +56 40 5 -40 231 591 90 54 0 +57 40 15 40 35 395 90 0 55 +58 38 5 -20 323 683 90 53 0 +59 38 15 -20 516 876 90 60 0 +60 35 5 20 416 776 90 0 59 +61 50 30 10 391 751 90 0 69 +62 50 35 -10 110 470 90 65 0 +63 50 40 50 15 375 90 0 74 +64 48 30 -10 483 843 90 67 0 +65 48 40 10 12 372 90 0 62 +66 47 35 -10 671 1031 90 68 0 +67 47 40 10 12 372 90 0 64 +68 45 30 10 576 936 90 0 66 +69 45 35 -10 763 1123 90 61 0 +70 95 30 30 242 602 90 0 73 +71 95 35 -10 147 507 90 76 0 +72 53 30 10 298 658 0 0 101 +73 92 30 -30 335 695 90 70 0 +74 53 35 -50 203 563 90 63 0 +75 45 65 -10 770 1130 90 1 0 +76 90 35 10 52 412 90 0 71 +77 88 30 10 429 789 0 0 102 +78 88 35 -30 50 410 90 81 0 +79 87 30 10 520 880 90 0 80 +80 85 25 -10 615 975 90 79 0 +81 85 35 30 47 407 90 0 78 +82 75 55 -10 215 575 90 83 0 +83 72 55 10 122 482 90 0 82 +84 70 58 -10 311 671 90 86 0 +85 68 60 30 404 764 90 0 91 +86 66 55 10 26 386 90 0 84 +87 65 55 20 25 385 90 0 89 +88 65 60 -10 497 857 90 90 0 +89 63 58 -20 590 950 90 87 0 +90 60 55 10 20 380 90 0 88 +91 60 60 -30 683 1043 90 85 0 +92 67 85 20 225 585 90 0 100 +93 65 85 -20 317 677 90 98 0 +94 65 82 -30 131 491 90 95 0 +95 62 80 30 38 398 90 0 94 +96 60 80 10 36 396 0 0 104 +97 60 85 30 412 772 90 0 99 +98 58 75 20 30 390 90 0 93 +99 55 80 -30 602 962 90 97 0 +100 55 85 -20 507 867 90 92 0 +101 53 30 -10 298 658 90 72 0 +102 88 30 -10 429 789 90 77 0 +103 5 45 -10 511 871 90 36 0 +104 60 80 -10 36 396 90 96 0 +105 23 52 -10 109 469 90 27 0 +106 28 30 -10 483 843 90 48 0 diff --git a/jsprit-instances/instances/lilim/lc1_2_1_d1.out b/jsprit-instances/instances/lilim/lc1_2_1_d1.out new file mode 100644 index 00000000..a547ba14 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc1_2_1_d1.out @@ -0,0 +1,11 @@ +-s +-ins +-rem +-dep +-two +-rel +-cro +-ex +-tou +-tra +#---------- pdp_200\lc1_2_1.txt ------------Create encoding diff --git a/jsprit-instances/instances/lilim/lc2000.txt b/jsprit-instances/instances/lilim/lc2000.txt new file mode 100644 index 00000000..9850aaac --- /dev/null +++ b/jsprit-instances/instances/lilim/lc2000.txt @@ -0,0 +1,7 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 -10 912 967 90 11 0 +2 45 70 -20 825 870 90 6 0 +3 42 66 10 65 146 90 0 75 +4 40 55 20 500 600 90 0 0 +5 50 65 -20 42 1000 90 0 0 diff --git a/jsprit-instances/instances/lilim/lc201.txt b/jsprit-instances/instances/lilim/lc201.txt new file mode 100644 index 00000000..9d8a87f4 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc201.txt @@ -0,0 +1,104 @@ +25 700 1 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 311 471 90 0 80 +2 45 70 30 213 373 90 0 94 +3 62 69 10 1167 1327 90 0 90 +4 60 66 -30 1261 1421 90 97 0 +5 42 65 10 25 185 90 0 77 +6 16 42 20 497 657 90 0 32 +7 58 70 -20 1073 1233 90 92 0 +8 34 60 20 2887 3047 90 0 21 +9 28 70 10 2601 2761 90 0 10 +10 35 66 -10 2791 2951 90 9 0 +11 35 69 -40 2698 2858 90 15 0 +12 25 85 -40 2119 2279 90 16 0 +13 22 75 -10 2405 2565 90 29 0 +14 22 85 -10 2026 2186 90 30 0 +15 20 80 40 2216 2376 90 0 11 +16 20 85 40 1934 2094 90 0 12 +17 18 75 -10 2311 2471 90 23 0 +18 15 75 20 1742 1902 90 0 19 +19 15 80 -20 1837 1997 90 18 0 +20 30 50 10 10 170 90 0 27 +21 30 56 -20 2983 3143 90 8 0 +22 28 52 20 22 182 90 0 24 +23 14 66 10 1643 1803 90 0 17 +24 25 50 -20 116 276 90 22 0 +25 22 66 -40 2504 2664 90 33 0 +26 8 62 10 1545 1705 0 0 101 +27 23 52 -10 209 369 90 20 0 +28 4 55 -20 1447 1607 90 37 0 +29 20 50 10 398 558 90 0 13 +30 20 55 10 303 463 90 0 14 +31 10 35 20 781 941 90 0 36 +32 10 40 -20 593 753 90 6 0 +33 8 40 40 685 845 90 0 25 +34 8 45 -30 1346 1506 90 38 0 +35 5 35 10 876 1036 90 0 39 +36 5 45 -20 1253 1413 90 31 0 +37 2 40 20 971 1131 90 0 28 +38 0 40 30 1063 1223 90 0 34 +39 0 45 -10 1158 1318 90 35 0 +40 36 18 10 1819 1979 90 0 50 +41 35 32 -30 2758 2918 90 46 0 +42 33 32 -10 2666 2826 90 43 0 +43 33 35 10 2573 2733 90 0 42 +44 32 20 -10 1913 2073 90 55 0 +45 30 30 -10 2105 2265 90 61 0 +46 34 25 30 2009 2169 90 0 41 +47 30 35 10 2480 2640 90 0 48 +48 36 40 -10 2856 3016 90 47 0 +49 48 20 -10 967 1127 90 69 0 +50 26 32 -10 2292 2452 90 40 0 +51 25 30 -50 2200 2360 90 74 0 +52 25 35 -20 2385 2545 90 53 0 +53 44 5 20 1256 1416 90 0 52 +54 42 10 -10 1160 1320 90 72 0 +55 42 15 10 1065 1225 90 0 44 +56 40 5 30 1350 1510 90 0 60 +57 38 15 -10 1725 1885 90 64 0 +58 38 5 -10 1442 1602 90 65 0 +59 38 10 -20 1630 1790 90 62 0 +60 35 5 -30 1535 1695 90 56 0 +61 50 30 10 401 561 90 0 45 +62 50 35 20 120 280 90 0 59 +63 50 40 50 25 185 90 0 66 +64 48 30 10 493 653 90 0 57 +65 44 25 10 871 1031 90 0 58 +66 47 35 -50 588 748 90 63 0 +67 47 40 10 12 172 90 0 68 +68 42 30 -10 776 936 90 67 0 +69 45 35 10 680 840 90 0 49 +70 95 30 30 2321 2481 90 0 73 +71 95 35 -30 2226 2386 90 88 0 +72 53 30 10 308 468 90 0 54 +73 92 30 -30 2414 2574 90 70 0 +74 53 35 50 213 373 90 0 51 +75 45 65 20 118 278 90 0 78 +76 90 35 -10 2131 2291 90 91 0 +77 72 45 -10 2900 3060 90 5 0 +78 78 40 -20 2802 2962 90 75 0 +79 87 30 -30 2608 2768 90 95 0 +80 85 25 -10 2513 2673 90 1 0 +81 85 35 30 2703 2863 90 0 87 +82 75 55 20 1925 2085 0 0 102 +83 72 55 -20 1832 1992 90 98 0 +84 70 58 20 1641 1801 90 0 85 +85 86 46 -20 2029 2189 90 84 0 +86 66 55 -10 1736 1896 90 99 0 +87 64 46 -30 3097 3257 90 81 0 +88 65 60 30 1546 1706 90 0 71 +89 56 64 10 1355 1515 90 0 96 +90 60 55 -10 3119 3279 90 3 0 +91 60 60 10 1451 1611 90 0 76 +92 67 85 20 694 854 90 0 7 +93 42 58 40 8 168 90 0 100 +94 65 82 -30 788 948 90 2 0 +95 62 80 30 881 1041 90 0 79 +96 62 40 -10 3001 3161 90 89 0 +97 60 85 30 597 757 90 0 4 +98 58 75 20 978 1138 90 0 83 +99 55 80 10 407 567 90 0 86 +100 55 85 -40 502 662 90 93 0 +101 8 62 -10 1545 1705 90 26 0 +102 75 55 -20 1925 2085 90 82 0 diff --git a/jsprit-instances/instances/lilim/lc202.txt b/jsprit-instances/instances/lilim/lc202.txt new file mode 100644 index 00000000..9bae2465 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc202.txt @@ -0,0 +1,104 @@ +25 700 1 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 0 3272 90 0 86 +2 45 70 30 0 3279 90 0 71 +3 62 69 -20 0 3270 90 75 0 +4 60 66 10 1261 1421 90 0 73 +5 42 65 10 0 3284 90 0 92 +6 16 42 20 497 657 90 0 19 +7 58 70 -30 0 3273 90 95 0 +8 34 60 -20 2887 3047 90 12 0 +9 28 70 -40 2601 2761 90 16 0 +10 35 66 -30 2791 2951 90 13 0 +11 35 69 -40 2698 2858 90 33 0 +12 25 85 20 0 3261 90 0 8 +13 22 75 30 2405 2565 90 0 10 +14 22 85 10 2026 2186 90 0 25 +15 20 80 -10 2216 2376 90 27 0 +16 20 85 40 1934 2094 90 0 9 +17 18 75 -30 2311 2471 90 38 0 +18 15 75 -20 1742 1902 90 37 0 +19 15 80 -20 1837 1997 90 6 0 +20 30 50 10 10 170 90 0 22 +21 30 56 -20 0 3288 90 34 0 +22 28 52 -10 22 182 90 20 0 +23 14 66 -30 1643 1803 90 32 0 +24 25 50 10 116 276 90 0 30 +25 22 66 -10 2504 2664 90 14 0 +26 8 62 -10 0 3265 90 35 0 +27 23 52 10 209 369 90 0 15 +28 4 55 -20 1447 1607 90 39 0 +29 20 50 10 398 558 90 0 36 +30 20 55 -10 303 463 90 24 0 +31 10 35 20 0 3266 0 0 102 +32 10 40 30 593 753 90 0 23 +33 8 40 40 685 845 90 0 11 +34 8 45 20 0 3267 90 0 21 +35 5 35 10 876 1036 90 0 26 +36 5 45 -10 1253 1413 90 29 0 +37 2 40 20 0 3260 90 0 18 +38 0 40 30 1063 1223 90 0 17 +39 0 45 20 1158 1318 90 0 28 +40 36 18 -30 1819 1979 90 56 0 +41 35 32 -10 2758 2918 90 47 0 +42 33 32 -20 2666 2826 90 53 0 +43 33 35 -10 2573 2733 90 44 0 +44 32 20 10 1913 2073 90 0 43 +45 30 30 10 2105 2265 90 0 52 +46 34 25 -10 2009 2169 90 64 0 +47 30 35 10 2480 2640 90 0 41 +48 36 40 -10 0 3289 90 49 0 +49 48 20 10 967 1127 90 0 48 +50 26 32 -10 0 3277 90 51 0 +51 25 30 10 2200 2360 90 0 50 +52 25 35 -10 0 3278 90 45 0 +53 44 5 20 1256 1416 90 0 42 +54 42 10 -20 1160 1320 90 62 0 +55 42 15 -10 1065 1225 90 68 0 +56 40 5 30 1350 1510 90 0 40 +57 38 15 -10 1725 1885 90 65 0 +58 38 5 -10 1442 1602 90 72 0 +59 38 10 -10 0 3259 90 67 0 +60 35 5 -10 1535 1695 90 61 0 +61 50 30 10 401 561 90 0 60 +62 50 35 20 120 280 90 0 54 +63 50 40 50 25 185 90 0 66 +64 48 30 10 493 653 90 0 46 +65 44 25 10 871 1031 90 0 57 +66 47 35 -50 588 748 90 63 0 +67 47 40 10 12 172 90 0 59 +68 42 30 10 776 936 90 0 55 +69 45 35 -50 680 840 90 74 0 +70 95 30 -30 2321 2481 90 85 0 +71 95 35 -30 2226 2386 90 2 0 +72 53 30 10 0 3276 90 0 58 +73 92 30 -10 2414 2574 90 4 0 +74 53 35 50 213 373 90 0 69 +75 45 65 20 0 3284 90 0 3 +76 90 35 -20 2131 2291 90 98 0 +77 72 45 10 2900 3060 90 0 96 +78 78 40 -10 2802 2962 90 94 0 +79 87 30 -30 2608 2768 90 88 0 +80 85 25 -20 2513 2673 90 82 0 +81 85 35 -10 2703 2863 90 91 0 +82 75 55 20 0 3264 90 0 80 +83 72 55 -30 0 3267 90 97 0 +84 70 58 -10 1641 1801 90 89 0 +85 86 46 30 0 3253 90 0 70 +86 66 55 -10 1736 1896 90 1 0 +87 64 46 20 3097 3257 90 0 90 +88 65 60 30 1546 1706 90 0 79 +89 56 64 10 1355 1515 90 0 84 +90 60 55 -20 3119 3279 90 87 0 +91 60 60 10 0 3277 90 0 81 +92 67 85 -10 694 854 90 5 0 +93 42 58 40 8 168 90 0 99 +94 65 82 10 0 3259 90 0 78 +95 62 80 30 0 3262 90 0 7 +96 62 40 -10 0 3275 90 77 0 +97 60 85 30 597 757 90 0 83 +98 58 75 20 0 3269 90 0 76 +99 55 80 -40 407 567 90 93 0 +100 55 85 20 502 662 0 0 101 +101 55 85 -20 502 662 90 100 0 +102 10 35 -20 0 3266 90 31 0 diff --git a/jsprit-instances/instances/lilim/lc203.txt b/jsprit-instances/instances/lilim/lc203.txt new file mode 100644 index 00000000..158f0fda --- /dev/null +++ b/jsprit-instances/instances/lilim/lc203.txt @@ -0,0 +1,104 @@ +25 700 1 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 0 3272 90 0 86 +2 45 70 30 0 3279 90 0 71 +3 62 69 -20 0 3270 90 75 0 +4 60 66 10 1261 1421 90 0 73 +5 42 65 10 0 3284 90 0 92 +6 16 42 -10 497 657 90 24 0 +7 58 70 -30 0 3273 90 95 0 +8 34 60 -10 2887 3047 90 19 0 +9 28 70 10 2601 2761 90 0 11 +10 35 66 10 2791 2951 0 0 102 +11 35 69 -10 2698 2858 90 9 0 +12 25 85 20 0 3261 90 0 13 +13 22 75 -20 2405 2565 90 12 0 +14 22 85 -20 0 3260 90 37 0 +15 20 80 -10 2216 2376 90 35 0 +16 20 85 -40 0 3259 90 33 0 +17 18 75 -10 2311 2471 90 29 0 +18 15 75 -20 0 3264 90 28 0 +19 15 80 10 0 3260 90 0 8 +20 30 50 10 0 3290 90 0 21 +21 30 56 -10 0 3288 90 20 0 +22 28 52 20 22 182 90 0 26 +23 14 66 -30 1643 1803 90 38 0 +24 25 50 10 0 3285 90 0 6 +25 22 66 -20 2504 2664 90 34 0 +26 8 62 -20 0 3265 90 22 0 +27 23 52 10 209 369 90 0 36 +28 4 55 20 0 3263 90 0 18 +29 20 50 10 0 3280 90 0 17 +30 20 55 10 303 463 90 0 32 +31 10 35 20 0 3266 90 0 39 +32 10 40 -10 0 3268 90 30 0 +33 8 40 40 685 845 90 0 16 +34 8 45 20 0 3267 90 0 25 +35 5 35 10 876 1036 90 0 15 +36 5 45 -10 1253 1413 90 27 0 +37 2 40 20 0 3260 90 0 14 +38 0 40 30 1063 1223 90 0 23 +39 0 45 -20 1158 1318 90 31 0 +40 36 18 10 1819 1979 90 0 46 +41 35 32 10 2758 2918 90 0 43 +42 33 32 -10 2666 2826 90 49 0 +43 33 35 -10 0 3283 90 41 0 +44 32 20 -10 1913 2073 90 72 0 +45 30 30 10 2105 2265 90 0 47 +46 34 25 -10 0 3274 90 40 0 +47 30 35 -10 0 3281 90 45 0 +48 36 40 -30 0 3289 90 58 0 +49 48 20 10 967 1127 90 0 42 +50 26 32 -10 0 3277 90 61 0 +51 25 30 -20 0 3275 90 60 0 +52 25 35 -10 0 3278 90 69 0 +53 44 5 -10 1256 1416 90 55 0 +54 42 10 -10 0 3259 90 68 0 +55 42 15 10 1065 1225 90 0 53 +56 40 5 -10 1350 1510 90 65 0 +57 38 15 -10 0 3264 90 59 0 +58 38 5 30 1442 1602 90 0 48 +59 38 10 10 0 3259 90 0 57 +60 35 5 20 0 3254 90 0 51 +61 50 30 10 0 3277 90 0 50 +62 50 35 -50 120 280 90 63 0 +63 50 40 50 0 3285 90 0 62 +64 48 30 10 493 653 90 0 66 +65 44 25 10 871 1031 90 0 56 +66 47 35 -10 588 748 90 64 0 +67 47 40 10 12 172 90 0 74 +68 42 30 10 776 936 90 0 54 +69 45 35 10 680 840 90 0 52 +70 95 30 -30 2321 2481 90 85 0 +71 95 35 -30 0 3242 90 2 0 +72 53 30 10 0 3276 90 0 44 +73 92 30 -10 0 3244 90 4 0 +74 53 35 -10 213 373 90 67 0 +75 45 65 20 0 3284 90 0 3 +76 90 35 -20 2131 2291 90 98 0 +77 72 45 10 2900 3060 90 0 96 +78 78 40 -10 2802 2962 90 94 0 +79 87 30 -30 2608 2768 90 88 0 +80 85 25 -20 2513 2673 90 82 0 +81 85 35 -10 0 3252 90 91 0 +82 75 55 20 0 3264 90 0 80 +83 72 55 -30 0 3267 90 97 0 +84 70 58 -10 1641 1801 90 89 0 +85 86 46 30 0 3253 90 0 70 +86 66 55 -10 0 3273 90 1 0 +87 64 46 20 3097 3257 90 0 90 +88 65 60 30 1546 1706 90 0 79 +89 56 64 10 0 3278 90 0 84 +90 60 55 -20 0 3279 90 87 0 +91 60 60 10 0 3277 90 0 81 +92 67 85 -10 694 854 90 5 0 +93 42 58 40 8 168 90 0 99 +94 65 82 10 0 3259 90 0 78 +95 62 80 30 0 3262 90 0 7 +96 62 40 -10 0 3275 90 77 0 +97 60 85 30 0 3259 90 0 83 +98 58 75 20 0 3269 90 0 76 +99 55 80 -40 407 567 90 93 0 +100 55 85 20 502 662 0 0 101 +101 55 85 -20 502 662 90 100 0 +102 35 66 -10 2791 2951 90 10 0 diff --git a/jsprit-instances/instances/lilim/lc204.txt b/jsprit-instances/instances/lilim/lc204.txt new file mode 100644 index 00000000..837e2767 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc204.txt @@ -0,0 +1,104 @@ +25 700 0 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 0 3272 90 0 80 +2 45 70 30 0 3279 90 0 94 +3 62 69 10 0 3270 90 0 90 +4 60 66 -30 1261 1421 90 97 0 +5 42 65 10 0 3284 90 0 77 +6 16 42 20 0 3274 90 0 32 +7 58 70 -20 0 3273 90 92 0 +8 34 60 20 2887 3047 90 0 21 +9 28 70 10 2601 2761 90 0 10 +10 35 66 -10 0 3283 90 9 0 +11 35 69 -40 2698 2858 90 15 0 +12 25 85 -40 0 3261 90 16 0 +13 22 75 -10 2405 2565 90 29 0 +14 22 85 -10 0 3260 90 30 0 +15 20 80 40 2216 2376 90 0 11 +16 20 85 40 0 3259 90 0 12 +17 18 75 -10 0 3266 90 23 0 +18 15 75 20 0 3264 90 0 19 +19 15 80 -20 0 3260 90 18 0 +20 30 50 10 0 3290 90 0 27 +21 30 56 -20 0 3288 90 8 0 +22 28 52 20 0 3287 90 0 24 +23 14 66 10 1643 1803 90 0 17 +24 25 50 -20 0 3285 90 22 0 +25 22 66 -40 2504 2664 90 33 0 +26 8 62 10 0 3265 0 0 101 +27 23 52 -10 0 3282 90 20 0 +28 4 55 -20 0 3263 90 37 0 +29 20 50 10 0 3280 90 0 13 +30 20 55 10 0 3279 90 0 14 +31 10 35 20 0 3266 90 0 36 +32 10 40 -20 0 3268 90 6 0 +33 8 40 40 0 3266 90 0 25 +34 8 45 -30 0 3267 90 38 0 +35 5 35 10 0 3261 90 0 39 +36 5 45 -20 0 3264 90 31 0 +37 2 40 20 0 3260 90 0 28 +38 0 40 30 1063 1223 90 0 34 +39 0 45 -10 0 3259 90 35 0 +40 36 18 10 0 3267 90 0 45 +41 35 32 -10 0 3281 90 61 0 +42 33 32 -50 0 3280 90 74 0 +43 33 35 -30 0 3283 90 46 0 +44 32 20 -10 1913 2073 90 55 0 +45 30 30 -10 0 3277 90 40 0 +46 34 25 30 0 3274 90 0 43 +47 30 35 -10 0 3281 90 52 0 +48 36 40 -10 0 3289 90 50 0 +49 48 20 -10 0 3268 90 69 0 +50 26 32 10 0 3277 90 0 48 +51 25 30 -20 0 3275 90 53 0 +52 25 35 10 0 3278 90 0 47 +53 44 5 20 1256 1416 90 0 51 +54 42 10 -10 0 3259 90 72 0 +55 42 15 10 1065 1225 90 0 44 +56 40 5 30 0 3255 90 0 60 +57 38 15 -10 0 3264 90 64 0 +58 38 5 -10 1442 1602 90 65 0 +59 38 10 -20 0 3259 90 62 0 +60 35 5 -30 0 3254 90 56 0 +61 50 30 10 0 3277 90 0 41 +62 50 35 20 120 280 90 0 59 +63 50 40 50 0 3285 90 0 66 +64 48 30 10 0 3278 90 0 57 +65 44 25 10 0 3274 90 0 58 +66 47 35 -50 0 3283 90 63 0 +67 47 40 10 12 172 90 0 68 +68 42 30 -10 0 3279 90 67 0 +69 45 35 10 680 840 90 0 49 +70 95 30 30 0 3241 90 0 73 +71 95 35 -30 0 3242 90 88 0 +72 53 30 10 0 3276 90 0 54 +73 92 30 -30 0 3244 90 70 0 +74 53 35 50 213 373 90 0 42 +75 45 65 20 0 3284 90 0 78 +76 90 35 -10 2131 2291 90 91 0 +77 72 45 -10 2900 3060 90 5 0 +78 78 40 -20 0 3260 90 75 0 +79 87 30 -30 2608 2768 90 95 0 +80 85 25 -10 0 3248 90 1 0 +81 85 35 30 0 3252 90 0 87 +82 75 55 20 0 3264 0 0 102 +83 72 55 -20 0 3267 90 98 0 +84 70 58 20 1641 1801 90 0 85 +85 86 46 -20 0 3253 90 84 0 +86 66 55 -10 0 3273 90 99 0 +87 64 46 -30 3097 3257 90 81 0 +88 65 60 30 0 3273 90 0 71 +89 56 64 10 0 3278 90 0 96 +90 60 55 -10 0 3279 90 3 0 +91 60 60 10 0 3277 90 0 76 +92 67 85 20 694 854 90 0 7 +93 42 58 40 0 3291 90 0 100 +94 65 82 -30 0 3259 90 2 0 +95 62 80 30 0 3262 90 0 79 +96 62 40 -10 0 3275 90 89 0 +97 60 85 30 0 3259 90 0 4 +98 58 75 20 0 3269 90 0 83 +99 55 80 10 407 567 90 0 86 +100 55 85 -40 502 662 90 93 0 +101 8 62 -10 0 3265 90 26 0 +102 75 55 -20 0 3264 90 82 0 diff --git a/jsprit-instances/instances/lilim/lc205.txt b/jsprit-instances/instances/lilim/lc205.txt new file mode 100644 index 00000000..72deb9c5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc205.txt @@ -0,0 +1,104 @@ +25 700 0 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 231 551 90 0 100 +2 45 70 30 133 453 90 0 7 +3 62 69 10 1087 1407 90 0 89 +4 60 66 10 1181 1501 90 0 77 +5 42 65 10 15 335 90 0 99 +6 16 42 20 417 737 90 0 17 +7 58 70 -30 993 1313 90 2 0 +8 34 60 -10 2807 3127 90 10 0 +9 28 70 -10 2521 2841 90 14 0 +10 35 66 10 2711 3031 90 0 8 +11 35 69 10 2618 2938 90 0 21 +12 25 85 -10 2039 2359 90 19 0 +13 22 75 -30 2325 2645 90 38 0 +14 22 85 10 1946 2266 90 0 9 +15 20 80 -10 2136 2456 90 35 0 +16 20 85 40 1854 2174 0 0 101 +17 18 75 -20 2231 2551 90 6 0 +18 15 75 20 1662 1982 90 0 25 +19 15 80 10 1757 2077 90 0 12 +20 30 50 10 10 330 90 0 27 +21 30 56 -10 2903 3223 90 11 0 +22 28 52 20 12 332 90 0 39 +23 14 66 -20 1563 1883 90 31 0 +24 25 50 10 36 356 90 0 34 +25 22 66 -20 2424 2744 90 18 0 +26 8 62 -10 1465 1785 90 36 0 +27 23 52 -10 129 449 90 20 0 +28 4 55 -20 1367 1687 90 37 0 +29 20 50 10 318 638 90 0 33 +30 20 55 10 223 543 90 0 32 +31 10 35 20 701 1021 90 0 23 +32 10 40 -10 513 833 90 30 0 +33 8 40 -10 605 925 90 29 0 +34 8 45 -10 1266 1586 90 24 0 +35 5 35 10 796 1116 90 0 15 +36 5 45 10 1173 1493 90 0 26 +37 2 40 20 891 1211 90 0 28 +38 0 40 30 983 1303 90 0 13 +39 0 45 -20 1078 1398 90 22 0 +40 36 18 -20 1739 2059 90 62 0 +41 35 32 -10 2678 2998 90 50 0 +42 33 32 -10 2586 2906 90 52 0 +43 33 35 -20 2493 2813 90 60 0 +44 32 20 -10 1833 2153 90 49 0 +45 30 30 -30 2025 2345 90 46 0 +46 34 25 30 1929 2249 90 0 45 +47 30 35 -20 2400 2720 90 53 0 +48 36 40 -10 2776 3096 90 61 0 +49 48 20 10 887 1207 90 0 44 +50 26 32 10 2212 2532 90 0 41 +51 25 30 -10 2120 2440 90 59 0 +52 25 35 10 2305 2625 90 0 42 +53 44 5 20 1176 1496 90 0 47 +54 42 10 40 1080 1400 90 0 58 +55 42 15 10 985 1305 90 0 57 +56 40 5 -10 1270 1590 90 66 0 +57 38 15 -10 1645 1965 90 55 0 +58 38 5 -40 1362 1682 90 54 0 +59 38 10 10 1550 1870 90 0 51 +60 35 5 20 1455 1775 90 0 43 +61 50 30 10 321 641 90 0 48 +62 50 35 20 40 360 90 0 40 +63 50 40 -10 14 334 90 67 0 +64 48 30 -10 413 733 90 72 0 +65 44 25 -50 791 1111 90 74 0 +66 47 35 10 508 828 90 0 56 +67 47 40 10 12 332 90 0 63 +68 42 30 -10 696 1016 90 69 0 +69 45 35 10 600 920 90 0 68 +70 95 30 -10 2241 2561 90 76 0 +71 95 35 20 2146 2466 90 0 87 +72 53 30 10 228 548 90 0 64 +73 92 30 -20 2334 2654 90 82 0 +74 53 35 50 133 453 90 0 65 +75 45 65 20 38 358 90 0 95 +76 90 35 10 2051 2371 90 0 70 +77 72 45 -10 2820 3140 90 4 0 +78 78 40 -10 2722 3042 90 79 0 +79 87 30 10 2528 2848 90 0 78 +80 85 25 10 2433 2753 90 0 90 +81 85 35 30 2623 2943 0 0 102 +82 75 55 20 1845 2165 90 0 73 +83 72 55 -30 1752 2072 90 88 0 +84 70 58 20 1561 1881 90 0 85 +85 86 46 -20 1949 2269 90 84 0 +86 66 55 10 1656 1976 90 0 96 +87 64 46 -20 2955 3275 90 71 0 +88 65 60 30 1466 1786 90 0 83 +89 56 64 -10 1275 1595 90 3 0 +90 60 55 -10 2959 3279 90 80 0 +91 60 60 -10 1371 1691 90 94 0 +92 67 85 -40 614 934 90 93 0 +93 42 58 40 8 328 90 0 92 +94 65 82 10 708 1028 90 0 91 +95 62 80 -20 801 1121 90 75 0 +96 62 40 -10 2921 3241 90 86 0 +97 60 85 30 517 837 90 0 98 +98 58 75 -30 898 1218 90 97 0 +99 55 80 -10 327 647 90 5 0 +100 55 85 -10 422 742 90 1 0 +101 20 85 -40 1854 2174 90 16 0 +102 85 35 -30 2623 2943 90 81 0 diff --git a/jsprit-instances/instances/lilim/lc206.txt b/jsprit-instances/instances/lilim/lc206.txt new file mode 100644 index 00000000..b95f44dc --- /dev/null +++ b/jsprit-instances/instances/lilim/lc206.txt @@ -0,0 +1,104 @@ +25 700 0 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 213 568 90 0 85 +2 45 70 30 22 563 90 0 95 +3 62 69 -20 1030 1463 90 98 0 +4 60 66 10 1154 1527 90 0 77 +5 42 65 10 15 402 90 0 75 +6 16 42 20 331 822 90 0 16 +7 58 70 20 965 1340 90 0 70 +8 34 60 20 2653 3280 0 0 102 +9 28 70 -10 2385 2976 90 19 0 +10 35 66 -10 2628 3113 90 20 0 +11 35 69 -10 2603 2952 90 14 0 +12 25 85 -20 1985 2412 90 18 0 +13 22 75 -20 2310 2659 90 17 0 +14 22 85 10 1846 2365 90 0 11 +15 20 80 -20 2077 2514 90 28 0 +16 20 85 -20 1763 2264 90 6 0 +17 18 75 20 2143 2638 90 0 13 +18 15 75 20 1560 2083 90 0 12 +19 15 80 10 1689 2144 90 0 9 +20 30 50 10 10 645 90 0 10 +21 30 56 -40 2675 3288 90 25 0 +22 28 52 20 12 505 90 0 39 +23 14 66 -10 1519 1926 90 36 0 +24 25 50 10 23 368 90 0 34 +25 22 66 40 2380 2787 90 0 21 +26 8 62 -10 1330 1919 90 35 0 +27 23 52 10 93 484 90 0 32 +28 4 55 20 1268 1785 90 0 15 +29 20 50 10 168 787 90 0 33 +30 20 55 10 170 595 90 0 38 +31 10 35 20 585 1136 90 0 37 +32 10 40 -10 448 897 90 27 0 +33 8 40 -10 499 1030 90 29 0 +34 8 45 -10 1190 1661 90 24 0 +35 5 35 10 666 1245 90 0 26 +36 5 45 10 1076 1589 90 0 23 +37 2 40 -20 772 1329 90 31 0 +38 0 40 -10 890 1395 90 30 0 +39 0 45 -20 1036 1439 90 22 0 +40 36 18 10 1612 2185 90 0 50 +41 35 32 -20 2599 3076 90 42 0 +42 33 32 20 2529 2962 90 0 41 +43 33 35 -30 2463 2842 90 46 0 +44 32 20 -10 1745 2240 90 55 0 +45 30 30 -10 1932 2437 90 61 0 +46 34 25 30 1884 2293 90 0 43 +47 30 35 10 2348 2771 90 0 48 +48 36 40 -10 2715 3156 90 47 0 +49 48 20 -10 812 1281 90 69 0 +50 26 32 -10 2018 2725 90 40 0 +51 25 30 -50 2015 2544 90 74 0 +52 25 35 -20 2201 2728 90 53 0 +53 44 5 20 1078 1593 90 0 52 +54 42 10 -10 998 1481 90 72 0 +55 42 15 10 897 1392 90 0 44 +56 40 5 30 1199 1660 90 0 60 +57 38 15 -10 1552 2057 90 64 0 +58 38 5 -10 1263 1780 90 65 0 +59 38 10 -20 1498 1921 90 62 0 +60 35 5 -30 1325 1904 90 56 0 +61 50 30 10 223 738 90 0 45 +62 50 35 20 18 474 90 0 59 +63 50 40 50 14 360 90 0 66 +64 48 30 10 246 899 90 0 57 +65 44 25 10 704 1197 90 0 58 +66 47 35 -50 393 942 90 63 0 +67 47 40 10 12 424 90 0 68 +68 42 30 -10 641 1070 90 67 0 +69 45 35 10 534 985 90 0 49 +70 95 30 -20 2119 2682 90 7 0 +71 95 35 -20 2079 2532 90 100 0 +72 53 30 10 131 644 90 0 54 +73 92 30 10 2169 2818 90 0 78 +74 53 35 50 87 498 90 0 51 +75 45 65 -10 15 607 90 5 0 +76 90 35 -20 2002 2419 90 92 0 +77 72 45 -10 2701 3258 90 4 0 +78 78 40 -10 2599 3164 90 73 0 +79 87 30 10 2505 2870 90 0 96 +80 85 25 -10 2369 2816 90 86 0 +81 85 35 -40 2563 3002 90 93 0 +82 75 55 -10 1783 2226 90 89 0 +83 72 55 10 1591 2232 90 0 90 +84 70 58 -30 1513 1928 90 97 0 +85 86 46 -10 1829 2388 90 1 0 +86 66 55 10 1604 2027 90 0 80 +87 64 46 -10 2976 3275 90 94 0 +88 65 60 30 1338 1913 0 0 101 +89 56 64 10 1116 1753 90 0 82 +90 60 55 -10 2789 3279 90 83 0 +91 60 60 -10 1349 1712 90 99 0 +92 67 85 20 518 1029 90 0 76 +93 42 58 40 8 509 90 0 81 +94 65 82 10 549 1186 90 0 87 +95 62 80 -30 744 1177 90 2 0 +96 62 40 -10 2713 3275 90 79 0 +97 60 85 30 397 956 90 0 84 +98 58 75 20 839 1276 90 0 3 +99 55 80 10 272 701 90 0 91 +100 55 85 20 373 790 90 0 71 +101 65 60 -30 1338 1913 90 88 0 +102 34 60 -20 2653 3280 90 8 0 diff --git a/jsprit-instances/instances/lilim/lc207.txt b/jsprit-instances/instances/lilim/lc207.txt new file mode 100644 index 00000000..7da835c2 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc207.txt @@ -0,0 +1,104 @@ +25 700 1 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 302 479 90 0 100 +2 45 70 30 157 428 90 0 7 +3 62 69 10 1138 1355 90 0 89 +4 60 66 10 1247 1434 90 0 77 +5 42 65 10 15 208 90 0 99 +6 16 42 20 209 944 90 0 15 +7 58 70 -30 1059 1246 90 2 0 +8 34 60 -10 2035 3288 90 10 0 +9 28 70 -40 2090 3271 90 16 0 +10 35 66 10 2311 3283 90 0 8 +11 35 69 10 2428 3127 90 0 21 +12 25 85 -10 1772 2625 90 35 0 +13 22 75 -30 2135 2834 90 38 0 +14 22 85 -20 1586 2625 90 18 0 +15 20 80 -20 1858 2733 90 6 0 +16 20 85 40 1512 2515 90 0 9 +17 18 75 20 1895 2886 90 0 25 +18 15 75 20 1299 2344 90 0 14 +19 15 80 10 1461 2372 0 0 101 +20 30 50 10 10 963 90 0 27 +21 30 56 -10 2062 3288 90 11 0 +22 28 52 20 12 752 90 0 39 +23 14 66 -20 1316 2129 90 31 0 +24 25 50 10 15 532 90 0 34 +25 22 66 -20 2177 2990 90 17 0 +26 8 62 -10 1036 2213 90 36 0 +27 23 52 -10 17 602 90 20 0 +28 4 55 -20 1010 2043 90 37 0 +29 20 50 10 20 948 90 0 33 +30 20 55 10 63 702 90 0 32 +31 10 35 20 309 1412 90 0 23 +32 10 40 -10 336 1009 90 30 0 +33 8 40 -10 234 1295 90 29 0 +34 8 45 -10 954 1897 90 24 0 +35 5 35 10 377 1534 90 0 12 +36 5 45 10 819 1846 90 0 26 +37 2 40 20 494 1607 90 0 28 +38 0 40 30 637 1648 90 0 13 +39 0 45 -20 834 1641 90 22 0 +40 36 18 -20 1468 2329 90 62 0 +41 35 32 -10 2480 3195 90 52 0 +42 33 32 -20 2421 3070 90 60 0 +43 33 35 -10 2368 2937 90 50 0 +44 32 20 -10 1621 2364 90 49 0 +45 30 30 -30 1805 2564 90 46 0 +46 34 25 30 1782 2395 90 0 45 +47 30 35 -20 2242 2877 90 53 0 +48 36 40 -10 2605 3266 90 61 0 +49 48 20 10 812 1281 90 0 44 +50 26 32 10 1842 2901 90 0 43 +51 25 30 -10 1883 2676 90 59 0 +52 25 35 10 2070 2859 90 0 41 +53 44 5 20 1078 1593 90 0 47 +54 42 10 40 998 1481 90 0 58 +55 42 15 10 897 1392 90 0 57 +56 40 5 -10 1083 1776 90 66 0 +57 38 15 -10 1426 2183 90 55 0 +58 38 5 -40 1133 1910 90 54 0 +59 38 10 10 1392 2027 90 0 51 +60 35 5 20 1180 2049 90 0 42 +61 50 30 10 223 738 90 0 48 +62 50 35 20 18 474 90 0 40 +63 50 40 -10 14 360 90 67 0 +64 48 30 -10 246 899 90 72 0 +65 44 25 -50 704 1197 90 74 0 +66 47 35 10 393 942 90 0 56 +67 47 40 10 12 424 90 0 63 +68 42 30 -10 641 1070 90 69 0 +69 45 35 10 534 985 90 0 68 +70 95 30 -10 2119 2682 90 76 0 +71 95 35 20 2192 2419 90 0 87 +72 53 30 10 131 644 90 0 64 +73 92 30 -20 2169 2818 90 82 0 +74 53 35 50 87 498 90 0 65 +75 45 65 20 49 346 90 0 95 +76 90 35 10 2106 2315 90 0 70 +77 72 45 -10 2701 3258 90 4 0 +78 78 40 -10 2599 3164 90 79 0 +79 87 30 10 2505 2870 90 0 78 +80 85 25 10 2369 2816 90 0 90 +81 85 35 30 2563 3002 0 0 102 +82 75 55 20 1894 2115 90 0 73 +83 72 55 -30 1751 2072 90 88 0 +84 70 58 20 1617 1824 90 0 85 +85 86 46 -20 1969 2248 90 84 0 +86 66 55 10 1710 1921 90 0 96 +87 64 46 -20 2976 3275 90 71 0 +88 65 60 30 1482 1769 90 0 83 +89 56 64 -10 1275 1594 90 3 0 +90 60 55 -10 2789 3279 90 80 0 +91 60 60 -10 1440 1621 90 94 0 +92 67 85 -40 646 901 90 93 0 +93 42 58 40 8 258 90 0 92 +94 65 82 10 708 1027 90 0 91 +95 62 80 -20 852 1069 90 75 0 +96 62 40 -10 2713 3275 90 86 0 +97 60 85 30 537 816 90 0 98 +98 58 75 -30 948 1167 90 97 0 +99 55 80 -10 379 594 90 5 0 +100 55 85 -10 477 686 90 1 0 +101 15 80 -10 1461 2372 90 19 0 +102 85 35 -30 2563 3002 90 81 0 diff --git a/jsprit-instances/instances/lilim/lc208.txt b/jsprit-instances/instances/lilim/lc208.txt new file mode 100644 index 00000000..febbb57d --- /dev/null +++ b/jsprit-instances/instances/lilim/lc208.txt @@ -0,0 +1,104 @@ +25 700 0 +0 40 50 0 0 3390 0 0 0 +1 52 75 10 71 711 90 0 100 +2 45 70 30 20 660 90 0 7 +3 62 69 10 927 1567 90 0 89 +4 60 66 10 1021 1661 90 0 77 +5 42 65 10 15 655 90 0 99 +6 16 42 20 257 897 90 0 15 +7 58 70 -30 833 1473 90 2 0 +8 34 60 -10 2647 3287 90 10 0 +9 28 70 -40 2361 3001 90 16 0 +10 35 66 10 2551 3191 90 0 8 +11 35 69 10 2458 3098 90 0 21 +12 25 85 -10 1879 2519 90 35 0 +13 22 75 -30 2165 2805 90 38 0 +14 22 85 -20 1786 2426 90 17 0 +15 20 80 -20 1976 2616 90 6 0 +16 20 85 40 1694 2334 90 0 9 +17 18 75 20 2071 2711 90 0 14 +18 15 75 20 1502 2142 90 0 25 +19 15 80 10 1597 2237 0 0 101 +20 30 50 10 10 650 90 0 27 +21 30 56 -10 2648 3288 90 11 0 +22 28 52 20 12 652 90 0 39 +23 14 66 -20 1403 2043 90 31 0 +24 25 50 10 15 655 90 0 34 +25 22 66 -20 2264 2904 90 18 0 +26 8 62 -10 1305 1945 90 36 0 +27 23 52 -10 17 657 90 20 0 +28 4 55 -20 1207 1847 90 37 0 +29 20 50 10 158 798 90 0 33 +30 20 55 10 63 703 90 0 32 +31 10 35 20 541 1181 90 0 23 +32 10 40 -10 353 993 90 30 0 +33 8 40 -10 445 1085 90 29 0 +34 8 45 -10 1106 1746 90 24 0 +35 5 35 10 636 1276 90 0 12 +36 5 45 10 1013 1653 90 0 26 +37 2 40 20 731 1371 90 0 28 +38 0 40 30 823 1463 90 0 13 +39 0 45 -20 918 1558 90 22 0 +40 36 18 -20 1579 2219 90 62 0 +41 35 32 -10 2518 3158 90 52 0 +42 33 32 -20 2426 3066 90 60 0 +43 33 35 -10 2333 2973 90 50 0 +44 32 20 -10 1673 2313 90 49 0 +45 30 30 -30 1865 2505 90 46 0 +46 34 25 30 1769 2409 90 0 45 +47 30 35 -20 2240 2880 90 53 0 +48 36 40 -10 2616 3256 90 61 0 +49 48 20 10 727 1367 90 0 44 +50 26 32 10 2052 2692 90 0 43 +51 25 30 -10 1960 2600 90 59 0 +52 25 35 10 2145 2785 90 0 41 +53 44 5 20 1016 1656 90 0 47 +54 42 10 40 920 1560 90 0 58 +55 42 15 10 825 1465 90 0 57 +56 40 5 -10 1110 1750 90 66 0 +57 38 15 -10 1485 2125 90 55 0 +58 38 5 -40 1202 1842 90 54 0 +59 38 10 10 1390 2030 90 0 51 +60 35 5 20 1295 1935 90 0 42 +61 50 30 10 161 801 90 0 48 +62 50 35 20 18 658 90 0 40 +63 50 40 -10 14 654 90 67 0 +64 48 30 -10 253 893 90 72 0 +65 44 25 -50 631 1271 90 74 0 +66 47 35 10 348 988 90 0 56 +67 47 40 10 12 652 90 0 63 +68 42 30 -10 536 1176 90 69 0 +69 45 35 10 440 1080 90 0 68 +70 95 30 -10 2081 2721 90 76 0 +71 95 35 20 1986 2626 90 0 87 +72 53 30 10 68 708 90 0 64 +73 92 30 -20 2174 2814 90 82 0 +74 53 35 50 19 659 90 0 65 +75 45 65 20 15 655 90 0 95 +76 90 35 10 1891 2531 90 0 70 +77 72 45 -10 2627 3267 90 4 0 +78 78 40 -10 2562 3202 90 79 0 +79 87 30 10 2368 3008 90 0 78 +80 85 25 10 2273 2913 90 0 90 +81 85 35 30 2463 3103 0 0 102 +82 75 55 20 1685 2325 90 0 73 +83 72 55 -30 1592 2232 90 88 0 +84 70 58 20 1401 2041 90 0 85 +85 86 46 -20 1789 2429 90 84 0 +86 66 55 10 1496 2136 90 0 96 +87 64 46 -20 2635 3275 90 71 0 +88 65 60 30 1306 1946 90 0 83 +89 56 64 -10 1115 1755 90 3 0 +90 60 55 -10 2639 3279 90 80 0 +91 60 60 -10 1211 1851 90 94 0 +92 67 85 -40 454 1094 90 93 0 +93 42 58 40 8 648 90 0 92 +94 65 82 10 548 1188 90 0 91 +95 62 80 -20 641 1281 90 75 0 +96 62 40 -10 2635 3275 90 86 0 +97 60 85 30 357 997 90 0 98 +98 58 75 -30 738 1378 90 97 0 +99 55 80 -10 167 807 90 5 0 +100 55 85 -10 262 902 90 1 0 +101 15 80 -10 1597 2237 90 19 0 +102 85 35 -30 2463 3103 90 81 0 diff --git a/jsprit-instances/instances/lilim/lc4000.txt b/jsprit-instances/instances/lilim/lc4000.txt new file mode 100644 index 00000000..1fd21cf3 --- /dev/null +++ b/jsprit-instances/instances/lilim/lc4000.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 1236 0 0 0 +1 45 68 -10 912 967 90 11 0 +2 45 70 -20 825 870 90 6 0 +3 42 66 10 65 146 90 0 75 +4 42 68 -10 727 782 90 9 0 +5 42 65 10 15 67 90 0 7 +6 40 69 20 621 702 90 0 2 +7 40 66 -10 170 225 90 5 0 +8 38 68 20 255 324 90 0 10 +9 38 70 10 534 605 90 0 4 +10 35 66 -20 357 410 90 8 0 +11 35 69 10 448 505 90 0 1 +12 25 85 -20 652 721 90 18 0 +13 22 75 30 30 92 90 0 17 +14 22 85 -40 567 620 90 16 0 +15 20 80 -10 384 429 90 19 0 +16 20 85 40 475 528 90 0 14 +17 18 75 -30 99 148 90 13 0 +18 15 75 20 179 254 90 0 12 +19 15 80 10 278 345 90 0 15 +20 30 50 10 10 73 90 0 24 +21 30 52 -10 914 965 90 30 0 +22 28 52 -20 812 883 90 28 0 +23 28 55 10 732 777 0 0 103 +24 25 50 -10 65 144 90 20 0 +25 25 52 40 169 224 90 0 27 +26 25 55 -10 622 701 90 29 0 +27 23 52 -40 261 316 90 25 0 +28 23 55 20 546 593 90 0 22 +29 20 50 10 358 405 90 0 26 +30 20 55 10 449 504 90 0 21 +31 10 35 -30 200 237 90 32 0 +32 10 40 30 31 100 90 0 31 +33 8 40 40 87 158 90 0 37 +34 8 45 -30 751 816 90 38 0 +35 5 35 10 283 344 90 0 39 +36 5 45 10 665 716 0 0 105 +37 2 40 -40 383 434 90 33 0 +38 0 40 30 479 522 90 0 34 +39 0 45 -10 567 624 90 35 0 +40 35 30 -20 264 321 90 42 0 +41 35 32 -10 166 235 90 43 0 +42 33 32 20 68 149 90 0 40 +43 33 35 10 16 80 90 0 41 +44 32 30 10 359 412 90 0 46 +45 30 30 10 541 600 90 0 48 +46 30 32 -10 448 509 90 44 0 +47 30 35 -10 1054 1127 90 49 0 +48 28 30 -10 632 693 90 45 0 +49 28 35 10 1001 1066 90 0 47 +50 26 32 10 815 880 90 0 52 +51 25 30 10 725 786 0 0 101 +52 25 35 -10 912 969 90 50 0 +53 44 5 20 286 347 90 0 58 +54 42 10 40 186 257 90 0 60 +55 42 15 -40 95 158 90 57 0 +56 40 5 30 385 436 90 0 59 +57 40 15 40 35 87 90 0 55 +58 38 5 -20 471 534 90 53 0 +59 38 15 -30 651 740 90 56 0 +60 35 5 -40 562 629 90 54 0 +61 50 30 -10 531 610 90 67 0 +62 50 35 20 262 317 90 0 68 +63 50 40 50 171 218 90 0 74 +64 48 30 10 632 693 0 0 102 +65 48 40 10 76 129 90 0 72 +66 47 35 10 826 875 90 0 69 +67 47 40 10 12 77 90 0 61 +68 45 30 -20 734 777 90 62 0 +69 45 35 -10 916 969 90 66 0 +70 95 30 -30 387 456 90 81 0 +71 95 35 20 293 360 90 0 77 +72 53 30 -10 450 505 90 65 0 +73 92 30 -10 478 551 90 76 0 +74 53 35 -50 353 412 90 63 0 +75 45 65 -10 997 1068 90 3 0 +76 90 35 10 203 260 90 0 73 +77 88 30 -20 574 643 90 71 0 +78 88 35 20 109 170 0 0 104 +79 87 30 10 668 731 90 0 80 +80 85 25 -10 769 820 90 79 0 +81 85 35 30 47 124 90 0 70 +82 75 55 20 369 420 90 0 85 +83 72 55 -20 265 338 90 87 0 +84 70 58 20 458 523 90 0 89 +85 68 60 -20 555 612 90 82 0 +86 66 55 10 173 238 90 0 91 +87 65 55 20 85 144 90 0 83 +88 65 60 -10 645 708 90 90 0 +89 63 58 -20 737 802 90 84 0 +90 60 55 10 20 84 90 0 88 +91 60 60 -10 836 889 90 86 0 +92 67 85 20 368 441 90 0 93 +93 65 85 -20 475 518 90 92 0 +94 65 82 -10 285 336 90 96 0 +95 62 80 -20 196 239 90 98 0 +96 60 80 10 95 156 90 0 94 +97 60 85 30 561 622 0 0 106 +98 58 75 20 30 84 90 0 95 +99 55 80 -20 743 820 90 100 0 +100 55 85 20 647 726 90 0 99 +101 25 30 -10 725 786 90 51 0 +102 48 30 -10 632 693 90 64 0 +103 28 55 -10 732 777 90 23 0 +104 88 35 -20 109 170 90 78 0 +105 5 45 -10 665 716 90 36 0 +106 60 85 -30 561 622 90 97 0 \ No newline at end of file diff --git a/jsprit-instances/instances/lilim/lr101.txt b/jsprit-instances/instances/lilim/lr101.txt new file mode 100644 index 00000000..07abbdb5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr101.txt @@ -0,0 +1,108 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -25 161 171 10 66 0 +2 35 17 7 50 60 10 0 73 +3 55 45 -6 116 126 10 69 0 +4 55 20 -6 149 159 10 56 0 +5 15 30 26 34 44 10 0 85 +6 25 30 -9 99 109 10 52 0 +7 20 50 -9 81 91 10 88 0 +8 10 43 9 95 105 10 0 17 +9 55 60 -21 97 107 10 30 0 +10 30 60 -27 124 134 10 31 0 +11 20 65 12 67 77 10 0 20 +12 50 35 -16 63 73 10 28 0 +13 30 25 -7 159 169 10 43 0 +14 15 10 20 32 42 10 0 38 +15 30 5 8 61 71 10 0 97 +16 10 20 19 75 85 10 0 91 +17 5 30 -9 157 167 10 8 0 +18 20 40 12 87 97 10 0 89 +19 15 60 -5 76 86 10 36 0 +20 45 65 -12 126 136 10 11 0 +21 45 20 11 62 72 10 0 41 +22 45 10 -18 97 107 10 75 0 +23 55 5 29 68 78 0 0 104 +24 65 35 3 153 163 10 0 80 +25 65 20 -2 172 182 10 55 0 +26 45 30 -9 132 142 10 40 0 +27 35 40 16 37 47 10 0 79 +28 41 37 16 39 49 10 0 12 +29 64 42 9 63 73 10 0 78 +30 40 60 21 71 81 10 0 9 +31 31 52 27 50 60 10 0 10 +32 35 69 -3 141 151 10 90 0 +33 53 52 11 37 47 10 0 34 +34 65 55 -11 117 127 10 33 0 +35 63 65 8 143 153 10 0 77 +36 2 60 5 41 51 10 0 19 +37 20 20 -11 134 144 10 83 0 +38 5 5 -20 83 93 10 14 0 +39 60 12 31 44 54 10 0 67 +40 40 25 9 85 95 10 0 26 +41 42 7 -11 97 107 10 21 0 +42 24 12 5 31 41 10 0 87 +43 23 3 7 132 142 10 0 13 +44 11 14 18 69 79 0 0 105 +45 6 38 16 32 42 10 0 84 +46 2 48 -27 117 127 10 47 0 +47 8 56 27 51 61 10 0 46 +48 13 52 -9 165 175 10 64 0 +49 6 68 -10 108 118 10 63 0 +50 47 47 -15 124 134 10 71 0 +51 49 58 10 88 98 0 0 101 +52 27 43 9 52 62 10 0 6 +53 37 31 14 95 105 0 0 106 +54 57 29 -13 140 150 10 76 0 +55 63 23 2 136 146 10 0 25 +56 53 12 6 130 140 10 0 4 +57 32 12 -2 101 111 10 92 0 +58 36 26 -25 200 210 10 72 0 +59 21 24 28 18 28 10 0 96 +60 17 34 -16 162 172 10 82 0 +61 12 24 13 76 86 10 0 93 +62 24 58 19 58 68 10 0 70 +63 27 69 10 34 44 10 0 49 +64 15 77 9 73 83 10 0 48 +65 62 77 20 51 61 10 0 81 +66 49 73 25 127 137 10 0 1 +67 67 5 -31 83 93 10 39 0 +68 56 39 36 142 152 0 0 103 +69 37 47 6 50 60 10 0 3 +70 37 56 -19 182 192 10 62 0 +71 57 68 15 77 87 10 0 50 +72 47 16 25 35 45 10 0 58 +73 44 17 -7 78 88 10 2 0 +74 46 13 8 149 159 0 0 102 +75 49 11 18 69 79 10 0 22 +76 49 42 13 73 83 10 0 54 +77 53 43 -8 179 189 10 35 0 +78 61 52 -9 96 106 10 29 0 +79 57 48 -16 92 102 10 27 0 +80 56 37 -3 182 192 10 24 0 +81 55 54 -20 94 104 10 65 0 +82 15 47 16 55 65 10 0 60 +83 14 37 11 44 54 10 0 37 +84 11 31 -16 101 111 10 45 0 +85 16 22 -26 91 101 10 5 0 +86 4 18 -10 94 104 10 98 0 +87 28 18 -5 93 103 10 42 0 +88 26 52 9 74 84 10 0 7 +89 26 35 -12 176 186 10 18 0 +90 31 67 3 95 105 10 0 32 +91 15 19 -19 160 170 10 16 0 +92 22 22 2 18 28 10 0 57 +93 18 24 -13 188 198 10 61 0 +94 26 27 -9 100 110 10 99 0 +95 25 24 20 39 49 10 0 100 +96 22 27 -28 135 145 10 59 0 +97 25 21 -8 133 143 10 15 0 +98 19 21 10 58 68 10 0 86 +99 20 26 9 83 93 10 0 94 +100 18 18 -20 185 195 10 95 0 +101 49 58 -10 88 98 10 51 0 +102 46 13 -8 149 159 10 74 0 +103 56 39 -36 142 152 10 68 0 +104 55 5 -29 68 78 10 23 0 +105 11 14 -18 69 79 10 44 0 +106 37 31 -14 95 105 10 53 0 diff --git a/jsprit-instances/instances/lilim/lr102.txt b/jsprit-instances/instances/lilim/lr102.txt new file mode 100644 index 00000000..e3b103f3 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr102.txt @@ -0,0 +1,112 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -13 0 204 10 50 0 +2 35 17 -20 0 202 10 14 0 +3 55 45 13 0 197 0 0 106 +4 55 20 19 149 159 10 0 25 +5 15 30 26 0 199 10 0 89 +6 25 30 -9 99 109 10 99 0 +7 20 50 5 0 198 10 0 19 +8 10 43 -19 95 105 10 62 0 +9 55 60 -21 97 107 10 30 0 +10 30 60 16 124 134 0 0 109 +11 20 65 -9 67 77 10 52 0 +12 50 35 -9 0 205 10 73 0 +13 30 25 -26 159 169 10 87 0 +14 15 10 20 32 42 10 0 2 +15 30 5 -5 61 71 10 42 0 +16 10 20 -41 75 85 10 85 0 +17 5 30 2 157 167 10 0 93 +18 20 40 -27 87 97 10 47 0 +19 15 60 -5 76 86 10 7 0 +20 45 65 -15 126 136 10 71 0 +21 45 20 -5 0 201 10 41 0 +22 45 10 18 97 107 0 0 103 +23 55 5 29 68 78 10 0 26 +24 65 35 -25 153 163 10 72 0 +25 65 20 -19 172 182 10 4 0 +26 45 30 -29 0 208 10 23 0 +27 35 40 16 37 47 0 0 101 +28 41 37 16 39 49 10 0 29 +29 64 42 -16 63 73 10 28 0 +30 40 60 21 71 81 10 0 9 +31 31 52 -3 0 202 10 90 0 +32 35 69 23 141 151 10 0 70 +33 53 52 11 37 47 10 0 51 +34 65 55 -3 0 183 10 78 0 +35 63 65 8 143 153 10 0 77 +36 2 60 5 41 51 0 0 104 +37 20 20 -1 0 198 10 91 0 +38 5 5 -18 83 93 10 44 0 +39 60 12 31 44 54 10 0 55 +40 40 25 9 85 95 10 0 53 +41 42 7 5 97 107 10 0 21 +42 24 12 5 31 41 10 0 15 +43 23 3 7 132 142 10 0 58 +44 11 14 18 69 79 10 0 38 +45 6 38 16 32 42 10 0 84 +46 2 48 -9 117 127 10 88 0 +47 8 56 27 51 61 10 0 18 +48 13 52 36 0 192 0 0 105 +49 6 68 30 108 118 10 0 82 +50 47 47 13 0 203 10 0 1 +51 49 58 -11 88 98 10 33 0 +52 27 43 9 0 208 10 0 11 +53 37 31 -9 95 105 10 40 0 +54 57 29 18 140 150 10 0 80 +55 63 23 -31 136 146 10 39 0 +56 53 12 -18 130 140 10 75 0 +57 32 12 7 101 111 10 0 97 +58 36 26 -7 200 210 10 43 0 +59 21 24 28 0 202 0 0 102 +60 17 34 3 162 172 0 0 107 +61 12 24 -11 76 86 10 83 0 +62 24 58 19 58 68 10 0 8 +63 27 69 10 34 44 10 0 64 +64 15 77 -10 73 83 10 63 0 +65 62 77 20 51 61 10 0 81 +66 49 73 25 127 137 0 0 108 +67 67 5 25 83 93 0 0 110 +68 56 39 -23 142 152 10 79 0 +69 37 47 6 50 60 10 0 76 +70 37 56 -23 182 192 10 32 0 +71 57 68 15 77 87 10 0 20 +72 47 16 25 0 197 10 0 24 +73 44 17 9 78 88 10 0 12 +74 46 13 -20 149 159 10 95 0 +75 49 11 18 0 192 10 0 56 +76 49 42 -6 73 83 10 69 0 +77 53 43 -8 179 189 10 35 0 +78 61 52 3 96 106 10 0 34 +79 57 48 23 92 102 10 0 68 +80 56 37 -18 182 192 10 54 0 +81 55 54 -20 94 104 10 65 0 +82 15 47 -30 0 196 10 49 0 +83 14 37 11 0 198 10 0 61 +84 11 31 -16 101 111 10 45 0 +85 16 22 41 0 196 10 0 16 +86 4 18 35 94 104 10 0 100 +87 28 18 26 93 103 10 0 13 +88 26 52 9 74 84 10 0 46 +89 26 35 -26 176 186 10 5 0 +90 31 67 3 95 105 10 0 31 +91 15 19 1 0 194 10 0 37 +92 22 22 2 18 28 10 0 98 +93 18 24 -2 188 198 10 17 0 +94 26 27 27 0 207 10 0 96 +95 25 24 20 0 205 10 0 74 +96 22 27 -27 0 204 10 94 0 +97 25 21 -7 133 143 10 57 0 +98 19 21 -2 0 198 10 92 0 +99 20 26 9 83 93 10 0 6 +100 18 18 -35 185 195 10 86 0 +101 35 40 -16 37 47 10 27 0 +102 21 24 -28 0 202 10 59 0 +103 45 10 -18 97 107 10 22 0 +104 2 60 -5 41 51 10 36 0 +105 13 52 -36 0 192 10 48 0 +106 55 45 -13 0 197 10 3 0 +107 17 34 -3 162 172 10 60 0 +108 49 73 -25 127 137 10 66 0 +109 30 60 -16 124 134 10 10 0 +110 67 5 -25 83 93 10 67 0 diff --git a/jsprit-instances/instances/lilim/lr103.txt b/jsprit-instances/instances/lilim/lr103.txt new file mode 100644 index 00000000..3003e6e4 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr103.txt @@ -0,0 +1,106 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -21 0 204 10 30 0 +2 35 17 7 0 202 10 0 4 +3 55 45 -17 0 197 10 26 0 +4 55 20 -7 149 159 10 2 0 +5 15 30 -11 0 199 10 83 0 +6 25 30 -3 99 109 10 60 0 +7 20 50 5 0 198 10 0 47 +8 10 43 9 95 105 10 0 46 +9 55 60 16 97 107 10 0 66 +10 30 60 -11 124 134 10 33 0 +11 20 65 -17 67 77 10 19 0 +12 50 35 19 0 205 10 0 80 +13 30 25 -12 159 169 10 97 0 +14 15 10 -10 0 187 10 98 0 +15 30 5 -7 61 71 10 43 0 +16 10 20 19 0 190 10 0 61 +17 5 30 -9 157 167 10 52 0 +18 20 40 12 0 204 10 0 89 +19 15 60 17 0 187 10 0 11 +20 45 65 9 0 188 10 0 51 +21 45 20 -5 0 201 10 41 0 +22 45 10 18 97 107 10 0 75 +23 55 5 29 68 78 10 0 29 +24 65 35 -2 0 190 10 55 0 +25 65 20 -6 172 182 10 56 0 +26 45 30 17 0 208 10 0 3 +27 35 40 16 37 47 10 0 69 +28 41 37 -20 0 213 10 65 0 +29 64 42 -29 0 190 10 23 0 +30 40 60 21 71 81 10 0 1 +31 31 52 -23 0 202 10 79 0 +32 35 69 -30 0 186 10 49 0 +33 53 52 11 37 47 10 0 10 +34 65 55 -3 0 183 10 78 0 +35 63 65 -15 143 153 10 71 0 +36 2 60 5 41 51 10 0 64 +37 20 20 -35 0 198 10 86 0 +38 5 5 16 83 93 10 0 91 +39 60 12 31 44 54 10 0 67 +40 40 25 9 85 95 10 0 68 +41 42 7 5 97 107 10 0 21 +42 24 12 5 31 41 10 0 72 +43 23 3 7 0 185 10 0 15 +44 11 14 18 69 79 10 0 85 +45 6 38 16 32 42 10 0 99 +46 2 48 -9 0 184 10 8 0 +47 8 56 -5 0 185 10 7 0 +48 13 52 36 0 192 10 0 82 +49 6 68 30 108 118 10 0 32 +50 47 47 13 0 203 10 0 76 +51 49 58 -9 0 193 10 20 0 +52 27 43 9 0 208 10 0 17 +53 37 31 14 95 105 0 0 101 +54 57 29 18 0 197 0 0 104 +55 63 23 2 136 146 10 0 24 +56 53 12 6 130 140 10 0 25 +57 32 12 7 0 196 10 0 73 +58 36 26 -8 200 210 10 74 0 +59 21 24 -22 0 202 10 93 0 +60 17 34 3 0 201 10 0 6 +61 12 24 -19 0 194 10 16 0 +62 24 58 19 58 68 10 0 84 +63 27 69 10 0 185 0 0 102 +64 15 77 -5 73 83 10 36 0 +65 62 77 20 51 61 10 0 28 +66 49 73 -16 127 137 10 9 0 +67 67 5 -31 83 93 10 39 0 +68 56 39 -9 142 152 10 40 0 +69 37 47 -16 50 60 10 27 0 +70 37 56 -3 182 192 10 90 0 +71 57 68 15 0 180 10 0 35 +72 47 16 -5 0 197 10 42 0 +73 44 17 -7 0 199 10 57 0 +74 46 13 8 149 159 10 0 58 +75 49 11 -18 0 192 10 22 0 +76 49 42 -13 73 83 10 50 0 +77 53 43 -26 179 189 10 81 0 +78 61 52 3 96 106 10 0 34 +79 57 48 23 92 102 10 0 31 +80 56 37 -19 182 192 10 12 0 +81 55 54 26 0 192 10 0 77 +82 15 47 -36 0 196 10 48 0 +83 14 37 11 0 198 10 0 5 +84 11 31 -19 101 111 10 62 0 +85 16 22 -18 0 196 10 44 0 +86 4 18 35 0 184 10 0 37 +87 28 18 -11 93 103 10 96 0 +88 26 52 9 74 84 0 0 103 +89 26 35 -12 0 211 10 18 0 +90 31 67 3 0 187 10 0 70 +91 15 19 -16 0 194 10 38 0 +92 22 22 2 18 28 10 0 100 +93 18 24 22 188 198 10 0 59 +94 26 27 27 0 207 10 0 95 +95 25 24 -27 0 205 10 94 0 +96 22 27 11 0 204 10 0 87 +97 25 21 12 0 202 10 0 13 +98 19 21 10 0 198 10 0 14 +99 20 26 -16 83 93 10 45 0 +100 18 18 -2 185 195 10 92 0 +101 37 31 -14 95 105 10 53 0 +102 27 69 -10 0 185 10 63 0 +103 26 52 -9 74 84 10 88 0 +104 57 29 -18 0 197 10 54 0 diff --git a/jsprit-instances/instances/lilim/lr104.txt b/jsprit-instances/instances/lilim/lr104.txt new file mode 100644 index 00000000..3c60a0fd --- /dev/null +++ b/jsprit-instances/instances/lilim/lr104.txt @@ -0,0 +1,106 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -16 0 204 10 28 0 +2 35 17 7 0 202 10 0 74 +3 55 45 -3 0 197 10 78 0 +4 55 20 19 149 159 10 0 25 +5 15 30 -11 0 199 10 83 0 +6 25 30 3 0 208 10 0 96 +7 20 50 -30 0 198 10 49 0 +8 10 43 -12 95 105 10 18 0 +9 55 60 -25 97 107 10 66 0 +10 30 60 -3 0 194 10 90 0 +11 20 65 12 67 77 10 0 31 +12 50 35 19 0 205 10 0 79 +13 30 25 -6 159 169 10 69 0 +14 15 10 20 0 187 10 0 44 +15 30 5 -7 61 71 10 43 0 +16 10 20 -35 0 190 10 86 0 +17 5 30 2 0 189 10 0 45 +18 20 40 12 0 204 10 0 8 +19 15 60 -1 0 187 10 46 0 +20 45 65 9 0 188 10 0 35 +21 45 20 11 0 201 10 0 54 +22 45 10 18 0 193 0 0 103 +23 55 5 -6 68 78 10 56 0 +24 65 35 3 0 190 10 0 29 +25 65 20 -19 172 182 10 4 0 +26 45 30 -14 0 208 10 53 0 +27 35 40 16 0 215 0 0 104 +28 41 37 16 0 213 10 0 1 +29 64 42 -3 0 190 10 24 0 +30 40 60 -5 0 194 10 70 0 +31 31 52 -12 0 202 10 11 0 +32 35 69 -9 0 186 10 88 0 +33 53 52 11 0 195 10 0 77 +34 65 55 14 0 183 10 0 81 +35 63 65 -9 0 178 10 20 0 +36 2 60 -36 0 178 10 48 0 +37 20 20 -17 0 198 10 100 0 +38 5 5 -10 83 93 10 98 0 +39 60 12 31 0 186 10 0 55 +40 40 25 9 0 208 0 0 102 +41 42 7 -26 0 191 10 87 0 +42 24 12 5 0 194 10 0 72 +43 23 3 7 0 185 10 0 15 +44 11 14 -20 69 79 10 14 0 +45 6 38 -2 0 190 10 17 0 +46 2 48 1 0 184 10 0 19 +47 8 56 -16 0 185 10 82 0 +48 13 52 36 0 192 10 0 36 +49 6 68 30 0 176 10 0 7 +50 47 47 -20 0 203 10 65 0 +51 49 58 -15 0 193 10 71 0 +52 27 43 9 0 208 10 0 62 +53 37 31 14 95 105 10 0 26 +54 57 29 -11 0 197 10 21 0 +55 63 23 -31 136 146 10 39 0 +56 53 12 6 0 190 10 0 23 +57 32 12 7 0 196 10 0 73 +58 36 26 -12 200 210 10 97 0 +59 21 24 28 0 202 10 0 99 +60 17 34 3 0 201 10 0 89 +61 12 24 13 0 194 10 0 91 +62 24 58 -9 58 68 10 52 0 +63 27 69 -9 0 185 10 64 0 +64 15 77 9 0 173 10 0 63 +65 62 77 20 0 170 10 0 50 +66 49 73 25 0 179 10 0 9 +67 67 5 -18 83 93 10 75 0 +68 56 39 -6 0 198 10 80 0 +69 37 47 6 50 60 10 0 13 +70 37 56 5 0 198 10 0 30 +71 57 68 15 0 180 10 0 51 +72 47 16 -5 0 197 10 42 0 +73 44 17 -7 0 199 10 57 0 +74 46 13 -7 149 159 10 2 0 +75 49 11 18 0 192 10 0 67 +76 49 42 13 73 83 10 0 95 +77 53 43 -11 179 189 10 33 0 +78 61 52 3 0 188 10 0 3 +79 57 48 -19 92 102 10 12 0 +80 56 37 6 0 198 10 0 68 +81 55 54 -14 0 192 10 34 0 +82 15 47 16 0 196 10 0 47 +83 14 37 11 0 198 10 0 5 +84 11 31 -27 101 111 10 94 0 +85 16 22 -2 0 196 10 92 0 +86 4 18 35 0 184 10 0 16 +87 28 18 26 93 103 10 0 41 +88 26 52 9 0 200 10 0 32 +89 26 35 -3 0 211 10 60 0 +90 31 67 3 0 187 10 0 10 +91 15 19 -13 0 194 10 61 0 +92 22 22 2 18 28 10 0 85 +93 18 24 22 0 199 0 0 101 +94 26 27 27 0 207 10 0 84 +95 25 24 -13 0 205 10 76 0 +96 22 27 -3 0 204 10 6 0 +97 25 21 12 0 202 10 0 58 +98 19 21 10 0 198 10 0 38 +99 20 26 -28 83 93 10 59 0 +100 18 18 17 185 195 10 0 37 +101 18 24 -22 0 199 10 93 0 +102 40 25 -9 0 208 10 40 0 +103 45 10 -18 0 193 10 22 0 +104 35 40 -16 0 215 10 27 0 diff --git a/jsprit-instances/instances/lilim/lr105.txt b/jsprit-instances/instances/lilim/lr105.txt new file mode 100644 index 00000000..6cc097b1 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr105.txt @@ -0,0 +1,108 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -11 151 181 10 33 0 +2 35 17 7 40 70 10 0 57 +3 55 45 13 106 136 10 0 80 +4 55 20 -29 139 169 10 23 0 +5 15 30 26 24 54 10 0 16 +6 25 30 -27 89 119 10 94 0 +7 20 50 -9 71 101 10 52 0 +8 10 43 -16 85 115 10 82 0 +9 55 60 16 87 117 10 0 66 +10 30 60 -3 114 144 10 90 0 +11 20 65 -9 57 87 10 64 0 +12 50 35 19 53 83 10 0 29 +13 30 25 -12 149 179 10 97 0 +14 15 10 20 32 62 10 0 86 +15 30 5 8 51 81 10 0 87 +16 10 20 -26 65 95 10 5 0 +17 5 30 2 147 177 10 0 60 +18 20 40 -11 77 107 10 83 0 +19 15 60 -5 66 96 10 36 0 +20 45 65 -15 116 146 10 71 0 +21 45 20 11 52 82 10 0 75 +22 45 10 18 87 117 10 0 58 +23 55 5 29 58 88 10 0 4 +24 65 35 -13 143 173 10 50 0 +25 65 20 -25 156 186 10 72 0 +26 45 30 -14 122 152 10 53 0 +27 35 40 16 27 57 10 0 69 +28 41 37 16 29 59 10 0 79 +29 64 42 -19 53 83 10 12 0 +30 40 60 21 61 91 10 0 35 +31 31 52 27 40 70 10 0 81 +32 35 69 23 131 161 0 0 104 +33 53 52 11 27 57 10 0 1 +34 65 55 14 107 137 10 0 77 +35 63 65 -21 133 163 10 30 0 +36 2 60 5 41 71 10 0 19 +37 20 20 -18 124 154 10 44 0 +38 5 5 -5 73 103 10 42 0 +39 60 12 31 34 64 10 0 55 +40 40 25 -13 75 105 10 76 0 +41 42 7 5 87 117 10 0 74 +42 24 12 5 25 55 10 0 38 +43 23 3 7 122 152 10 0 100 +44 11 14 18 59 89 10 0 37 +45 6 38 16 29 59 0 0 102 +46 2 48 1 107 137 10 0 48 +47 8 56 27 41 71 10 0 49 +48 13 52 -1 155 185 10 46 0 +49 6 68 -27 98 128 10 47 0 +50 47 47 13 114 144 10 0 24 +51 49 58 10 78 108 10 0 78 +52 27 43 9 42 72 10 0 7 +53 37 31 14 85 115 10 0 26 +54 57 29 -25 130 160 10 67 0 +55 63 23 -31 126 156 10 39 0 +56 53 12 -9 120 150 10 73 0 +57 32 12 -7 91 121 10 2 0 +58 36 26 -18 180 210 10 22 0 +59 21 24 28 17 47 10 0 61 +60 17 34 -2 152 182 10 17 0 +61 12 24 -28 66 96 10 59 0 +62 24 58 19 48 78 10 0 88 +63 27 69 10 34 64 10 0 70 +64 15 77 9 63 93 10 0 11 +65 62 77 20 49 79 0 0 105 +66 49 73 -16 117 147 10 9 0 +67 67 5 25 73 103 10 0 54 +68 56 39 36 132 162 0 0 101 +69 37 47 -16 40 70 10 27 0 +70 37 56 -10 168 198 10 63 0 +71 57 68 15 67 97 10 0 20 +72 47 16 25 25 55 10 0 25 +73 44 17 9 68 98 10 0 56 +74 46 13 -5 139 169 10 41 0 +75 49 11 -11 59 89 10 21 0 +76 49 42 13 63 93 10 0 40 +77 53 43 -14 169 199 10 34 0 +78 61 52 -10 86 116 10 51 0 +79 57 48 -16 82 112 10 28 0 +80 56 37 -13 168 198 10 3 0 +81 55 54 -27 84 114 10 31 0 +82 15 47 16 45 75 10 0 8 +83 14 37 11 34 64 10 0 18 +84 11 31 -41 91 121 10 85 0 +85 16 22 41 81 111 10 0 84 +86 4 18 -20 84 114 10 14 0 +87 28 18 -8 83 113 10 15 0 +88 26 52 -19 64 94 10 62 0 +89 26 35 15 166 196 0 0 103 +90 31 67 3 85 115 10 0 10 +91 15 19 1 150 180 10 0 93 +92 22 22 -20 18 48 10 95 0 +93 18 24 -1 169 199 10 91 0 +94 26 27 27 90 120 10 0 6 +95 25 24 20 29 59 10 0 92 +96 22 27 11 125 155 0 0 106 +97 25 21 12 123 153 10 0 13 +98 19 21 10 48 78 10 0 99 +99 20 26 -10 73 103 10 98 0 +100 18 18 -7 165 195 10 43 0 +101 56 39 -36 132 162 10 68 0 +102 6 38 -16 29 59 10 45 0 +103 26 35 -15 166 196 10 89 0 +104 35 69 -23 131 161 10 32 0 +105 62 77 -20 49 79 10 65 0 +106 22 27 -11 125 155 10 96 0 diff --git a/jsprit-instances/instances/lilim/lr106.txt b/jsprit-instances/instances/lilim/lr106.txt new file mode 100644 index 00000000..a029f1c7 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr106.txt @@ -0,0 +1,106 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -21 0 204 10 30 0 +2 35 17 -8 0 202 10 74 0 +3 55 45 13 0 197 10 0 77 +4 55 20 -18 139 169 10 54 0 +5 15 30 26 0 199 10 0 60 +6 25 30 3 89 119 10 0 89 +7 20 50 -30 0 198 10 49 0 +8 10 43 9 85 115 10 0 17 +9 55 60 16 87 117 10 0 35 +10 30 60 -9 114 144 10 64 0 +11 20 65 -10 57 87 10 63 0 +12 50 35 -23 0 205 10 79 0 +13 30 25 -5 149 179 10 42 0 +14 15 10 -28 32 62 10 59 0 +15 30 5 8 51 81 10 0 87 +16 10 20 -41 65 95 10 85 0 +17 5 30 -9 147 177 10 8 0 +18 20 40 -16 77 107 10 45 0 +19 15 60 17 66 96 10 0 82 +20 45 65 -19 116 146 10 62 0 +21 45 20 11 0 201 10 0 67 +22 45 10 -17 87 117 10 26 0 +23 55 5 -25 58 88 10 72 0 +24 65 35 -26 143 173 10 81 0 +25 65 20 6 156 186 0 0 101 +26 45 30 17 0 208 10 0 22 +27 35 40 16 27 57 0 0 103 +28 41 37 16 29 59 10 0 73 +29 64 42 9 53 83 10 0 78 +30 40 60 21 61 91 10 0 1 +31 31 52 -3 0 202 10 90 0 +32 35 69 -9 131 161 10 88 0 +33 53 52 -13 27 57 10 50 0 +34 65 55 -20 0 183 10 65 0 +35 63 65 -16 133 163 10 9 0 +36 2 60 -36 41 71 10 48 0 +37 20 20 8 0 198 10 0 43 +38 5 5 16 73 103 10 0 93 +39 60 12 31 34 64 10 0 55 +40 40 25 9 75 105 10 0 53 +41 42 7 5 87 117 10 0 75 +42 24 12 5 25 55 10 0 13 +43 23 3 -8 122 152 10 37 0 +44 11 14 18 59 89 10 0 86 +45 6 38 16 29 59 10 0 18 +46 2 48 1 107 137 0 0 102 +47 8 56 27 41 71 10 0 52 +48 13 52 36 0 192 10 0 36 +49 6 68 30 98 128 10 0 7 +50 47 47 13 0 203 10 0 33 +51 49 58 -15 78 108 10 71 0 +52 27 43 -27 0 208 10 47 0 +53 37 31 -9 85 115 10 40 0 +54 57 29 18 130 160 10 0 4 +55 63 23 -31 126 156 10 39 0 +56 53 12 6 120 150 10 0 58 +57 32 12 -27 91 121 10 94 0 +58 36 26 -6 180 210 10 56 0 +59 21 24 28 0 202 10 0 14 +60 17 34 -26 152 182 10 5 0 +61 12 24 13 66 96 10 0 99 +62 24 58 19 48 78 10 0 20 +63 27 69 10 34 64 10 0 11 +64 15 77 9 63 93 10 0 10 +65 62 77 20 49 79 10 0 34 +66 49 73 25 117 147 10 0 70 +67 67 5 -11 73 103 10 21 0 +68 56 39 36 132 162 10 0 80 +69 37 47 6 40 70 10 0 76 +70 37 56 -25 168 198 10 66 0 +71 57 68 15 67 97 10 0 51 +72 47 16 25 0 197 10 0 23 +73 44 17 -16 68 98 10 28 0 +74 46 13 8 139 169 10 0 2 +75 49 11 -5 0 192 10 41 0 +76 49 42 -6 63 93 10 69 0 +77 53 43 -13 169 199 10 3 0 +78 61 52 -9 86 116 10 29 0 +79 57 48 23 82 112 10 0 12 +80 56 37 -36 168 198 10 68 0 +81 55 54 26 84 114 10 0 24 +82 15 47 -17 0 196 10 19 0 +83 14 37 11 0 198 10 0 84 +84 11 31 -11 91 121 10 83 0 +85 16 22 41 0 196 10 0 16 +86 4 18 -18 84 114 10 44 0 +87 28 18 -8 83 113 10 15 0 +88 26 52 9 64 94 10 0 32 +89 26 35 -3 166 196 10 6 0 +90 31 67 3 85 115 10 0 31 +91 15 19 -11 0 194 10 96 0 +92 22 22 2 18 48 10 0 95 +93 18 24 -16 169 199 10 38 0 +94 26 27 27 0 207 10 0 57 +95 25 24 -2 0 205 10 92 0 +96 22 27 11 0 204 10 0 91 +97 25 21 12 123 153 0 0 104 +98 19 21 -17 0 198 10 100 0 +99 20 26 -13 73 103 10 61 0 +100 18 18 17 165 195 10 0 98 +101 65 20 -6 156 186 10 25 0 +102 2 48 -1 107 137 10 46 0 +103 35 40 -16 27 57 10 27 0 +104 25 21 -12 123 153 10 97 0 diff --git a/jsprit-instances/instances/lilim/lr107.txt b/jsprit-instances/instances/lilim/lr107.txt new file mode 100644 index 00000000..a2af365e --- /dev/null +++ b/jsprit-instances/instances/lilim/lr107.txt @@ -0,0 +1,106 @@ +25 200 0 +0 35 35 0 0 230 0 0 0 +1 41 49 -16 0 204 10 27 0 +2 35 17 -26 0 202 10 87 0 +3 55 45 -25 0 197 10 67 0 +4 55 20 -6 139 169 10 56 0 +5 15 30 26 0 199 0 0 103 +6 25 30 -9 89 119 10 40 0 +7 20 50 5 0 198 0 0 102 +8 10 43 9 85 115 10 0 84 +9 55 60 16 87 117 10 0 35 +10 30 60 16 114 144 10 0 32 +11 20 65 12 57 87 10 0 89 +12 50 35 -6 0 205 10 80 0 +13 30 25 -11 149 179 10 96 0 +14 15 10 20 0 187 10 0 86 +15 30 5 -7 51 81 10 43 0 +16 10 20 19 0 190 10 0 100 +17 5 30 -5 147 177 10 36 0 +18 20 40 -30 0 204 10 49 0 +19 15 60 17 0 187 10 0 48 +20 45 65 9 0 188 10 0 81 +21 45 20 11 0 201 10 0 39 +22 45 10 -5 87 117 10 42 0 +23 55 5 -17 58 88 10 26 0 +24 65 35 3 0 190 10 0 77 +25 65 20 -5 156 186 10 41 0 +26 45 30 17 0 208 10 0 23 +27 35 40 16 27 57 10 0 1 +28 41 37 -3 0 213 10 78 0 +29 64 42 -2 0 190 10 55 0 +30 40 60 -10 61 91 10 51 0 +31 31 52 -11 0 202 10 33 0 +32 35 69 -16 0 186 10 10 0 +33 53 52 11 27 57 10 0 31 +34 65 55 14 0 183 10 0 68 +35 63 65 -16 133 163 10 9 0 +36 2 60 5 41 71 10 0 17 +37 20 20 -1 0 198 10 91 0 +38 5 5 16 73 103 10 0 97 +39 60 12 -11 34 64 10 21 0 +40 40 25 9 75 105 10 0 6 +41 42 7 5 87 117 10 0 25 +42 24 12 5 25 55 10 0 22 +43 23 3 7 0 185 10 0 15 +44 11 14 -10 59 89 10 98 0 +45 6 38 -3 29 59 10 60 0 +46 2 48 -27 0 184 10 47 0 +47 8 56 27 0 185 10 0 46 +48 13 52 -17 0 192 10 19 0 +49 6 68 30 98 128 10 0 18 +50 47 47 -20 0 203 10 65 0 +51 49 58 10 0 193 10 0 30 +52 27 43 9 0 208 10 0 82 +53 37 31 14 85 115 10 0 95 +54 57 29 -18 0 197 10 75 0 +55 63 23 2 126 156 10 0 29 +56 53 12 6 120 150 10 0 4 +57 32 12 7 0 196 10 0 72 +58 36 26 -28 180 210 10 59 0 +59 21 24 28 0 202 10 0 58 +60 17 34 3 0 201 10 0 45 +61 12 24 13 0 194 10 0 93 +62 24 58 19 48 78 10 0 64 +63 27 69 -9 0 185 10 88 0 +64 15 77 -19 63 93 10 62 0 +65 62 77 20 49 79 10 0 50 +66 49 73 25 117 147 10 0 71 +67 67 5 25 73 103 10 0 3 +68 56 39 -14 132 162 10 34 0 +69 37 47 6 40 70 10 0 76 +70 37 56 -3 168 198 10 90 0 +71 57 68 -25 0 180 10 66 0 +72 47 16 -7 0 197 10 57 0 +73 44 17 -8 0 199 10 74 0 +74 46 13 8 139 169 10 0 73 +75 49 11 18 0 192 10 0 54 +76 49 42 -6 63 93 10 69 0 +77 53 43 -3 169 199 10 24 0 +78 61 52 3 86 116 10 0 28 +79 57 48 23 82 112 0 0 101 +80 56 37 6 168 198 10 0 12 +81 55 54 -9 0 192 10 20 0 +82 15 47 -9 0 196 10 52 0 +83 14 37 11 0 198 10 0 99 +84 11 31 -9 91 121 10 8 0 +85 16 22 41 0 196 0 0 104 +86 4 18 -20 0 184 10 14 0 +87 28 18 26 83 113 10 0 2 +88 26 52 9 64 94 10 0 63 +89 26 35 -12 0 211 10 11 0 +90 31 67 3 0 187 10 0 70 +91 15 19 1 0 194 10 0 37 +92 22 22 -27 18 48 10 94 0 +93 18 24 -13 169 199 10 61 0 +94 26 27 27 0 207 10 0 92 +95 25 24 -14 0 205 10 53 0 +96 22 27 11 0 204 10 0 13 +97 25 21 -16 0 202 10 38 0 +98 19 21 10 0 198 10 0 44 +99 20 26 -11 73 103 10 83 0 +100 18 18 -19 165 195 10 16 0 +101 57 48 -23 82 112 10 79 0 +102 20 50 -5 0 198 10 7 0 +103 15 30 -26 0 199 10 5 0 +104 16 22 -41 0 196 10 85 0 diff --git a/jsprit-instances/instances/lilim/lr108.txt b/jsprit-instances/instances/lilim/lr108.txt new file mode 100644 index 00000000..451c0591 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr108.txt @@ -0,0 +1,102 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 10 0 204 10 0 76 +2 35 17 7 0 202 10 0 74 +3 55 45 -23 0 197 10 79 0 +4 55 20 -25 139 169 10 67 0 +5 15 30 26 0 199 10 0 17 +6 25 30 3 0 208 10 0 59 +7 20 50 -9 0 198 10 8 0 +8 10 43 9 85 115 10 0 7 +9 55 60 -6 87 117 10 80 0 +10 30 60 -3 0 194 10 90 0 +11 20 65 -9 57 87 10 88 0 +12 50 35 19 0 205 10 0 81 +13 30 25 23 149 179 10 0 58 +14 15 10 20 0 187 10 0 86 +15 30 5 8 51 81 10 0 42 +16 10 20 19 0 190 10 0 61 +17 5 30 -26 0 189 10 5 0 +18 20 40 12 0 204 10 0 46 +19 15 60 -16 0 187 10 82 0 +20 45 65 -5 0 188 10 70 0 +21 45 20 -7 0 201 10 57 0 +22 45 10 -26 0 193 10 87 0 +23 55 5 29 58 88 10 0 25 +24 65 35 3 0 190 10 0 51 +25 65 20 -29 156 186 10 23 0 +26 45 30 -5 0 208 10 41 0 +27 35 40 16 0 215 10 0 94 +28 41 37 -14 0 213 10 77 0 +29 64 42 9 0 190 10 0 33 +30 40 60 21 0 194 10 0 68 +31 31 52 27 0 202 10 0 63 +32 35 69 -30 0 186 10 49 0 +33 53 52 -9 0 195 10 29 0 +34 65 55 14 0 183 10 0 78 +35 63 65 -15 0 178 10 71 0 +36 2 60 5 0 178 10 0 47 +37 20 20 -41 0 198 10 85 0 +38 5 5 16 73 103 10 0 100 +39 60 12 -18 0 186 10 75 0 +40 40 25 -13 0 208 10 50 0 +41 42 7 5 0 191 10 0 26 +42 24 12 -8 0 194 10 15 0 +43 23 3 7 0 185 10 0 73 +44 11 14 -2 59 89 10 92 0 +45 6 38 16 0 190 10 0 60 +46 2 48 -12 0 184 10 18 0 +47 8 56 -5 0 185 10 36 0 +48 13 52 -9 0 192 10 52 0 +49 6 68 30 0 176 10 0 32 +50 47 47 13 0 203 10 0 40 +51 49 58 -3 0 193 10 24 0 +52 27 43 9 0 208 10 0 48 +53 37 31 14 85 115 10 0 97 +54 57 29 -2 0 197 10 55 0 +55 63 23 2 126 156 10 0 54 +56 53 12 -25 0 190 10 72 0 +57 32 12 7 0 196 10 0 21 +58 36 26 -23 180 210 10 13 0 +59 21 24 -3 0 202 10 6 0 +60 17 34 -16 0 201 10 45 0 +61 12 24 -19 0 194 10 16 0 +62 24 58 19 48 78 10 0 64 +63 27 69 -27 0 185 10 31 0 +64 15 77 -19 0 173 10 62 0 +65 62 77 -25 0 170 10 66 0 +66 49 73 25 0 179 10 0 65 +67 67 5 25 73 103 10 0 4 +68 56 39 -21 0 198 10 30 0 +69 37 47 6 40 70 10 0 95 +70 37 56 5 0 198 10 0 20 +71 57 68 15 0 180 10 0 35 +72 47 16 25 0 197 10 0 56 +73 44 17 -7 0 199 10 43 0 +74 46 13 -7 139 169 10 2 0 +75 49 11 18 0 192 10 0 39 +76 49 42 -10 63 93 10 1 0 +77 53 43 14 169 199 10 0 28 +78 61 52 -14 0 188 10 34 0 +79 57 48 23 82 112 10 0 3 +80 56 37 6 0 198 10 0 9 +81 55 54 -19 0 192 10 12 0 +82 15 47 16 0 196 10 0 19 +83 14 37 -7 0 198 10 84 0 +84 11 31 7 91 121 10 0 83 +85 16 22 41 0 196 10 0 37 +86 4 18 -20 0 184 10 14 0 +87 28 18 26 83 113 10 0 22 +88 26 52 9 0 200 10 0 11 +89 26 35 -9 0 211 10 99 0 +90 31 67 3 0 187 10 0 10 +91 15 19 -10 0 194 10 98 0 +92 22 22 2 18 48 10 0 44 +93 18 24 -11 0 199 10 96 0 +94 26 27 -16 0 207 10 27 0 +95 25 24 -6 0 205 10 69 0 +96 22 27 11 0 204 10 0 93 +97 25 21 -14 0 202 10 53 0 +98 19 21 10 0 198 10 0 91 +99 20 26 9 73 103 10 0 89 +100 18 18 -16 165 195 10 38 0 diff --git a/jsprit-instances/instances/lilim/lr109.txt b/jsprit-instances/instances/lilim/lr109.txt new file mode 100644 index 00000000..7131b15c --- /dev/null +++ b/jsprit-instances/instances/lilim/lr109.txt @@ -0,0 +1,108 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -20 133 198 10 65 0 +2 35 17 7 22 87 10 0 55 +3 55 45 13 98 143 10 0 68 +4 55 20 -8 123 184 10 74 0 +5 15 30 26 20 93 10 0 61 +6 25 30 3 76 131 10 0 96 +7 20 50 -27 61 110 10 31 0 +8 10 43 -9 75 124 10 88 0 +9 55 60 -19 74 129 10 12 0 +10 30 60 16 107 150 0 0 101 +11 20 65 12 42 101 10 0 90 +12 50 35 19 38 97 10 0 9 +13 30 25 -10 131 196 10 98 0 +14 15 10 -18 32 114 10 44 0 +15 30 5 -20 35 96 10 95 0 +16 10 20 -11 52 107 10 83 0 +17 5 30 2 124 189 10 0 89 +18 20 40 12 69 114 10 0 60 +19 15 60 -16 52 109 10 45 0 +20 45 65 9 105 156 10 0 70 +21 45 20 11 37 96 10 0 25 +22 45 10 -31 76 127 10 39 0 +23 55 5 29 43 102 10 0 75 +24 65 35 -26 124 190 10 81 0 +25 65 20 -11 121 186 10 21 0 +26 45 30 -14 112 161 10 53 0 +27 35 40 16 8 75 10 0 71 +28 41 37 16 11 76 10 0 79 +29 64 42 9 37 98 10 0 78 +30 40 60 -6 49 102 10 69 0 +31 31 52 27 24 85 10 0 7 +32 35 69 -9 116 175 10 64 0 +33 53 52 11 24 92 10 0 35 +34 65 55 14 96 147 0 0 102 +35 63 65 -11 116 178 10 33 0 +36 2 60 5 41 112 10 0 48 +37 20 20 8 113 164 10 0 93 +38 5 5 -28 60 115 10 59 0 +39 60 12 31 33 110 10 0 22 +40 40 25 -25 65 114 10 72 0 +41 42 7 -25 72 131 10 67 0 +42 24 12 -2 25 91 10 92 0 +43 23 3 -26 111 162 10 87 0 +44 11 14 18 45 102 10 0 14 +45 6 38 16 29 99 10 0 19 +46 2 48 -9 92 151 10 52 0 +47 8 56 -16 34 105 10 82 0 +48 13 52 -5 128 192 10 36 0 +49 6 68 30 93 132 0 0 106 +50 47 47 -14 102 155 10 77 0 +51 49 58 10 64 121 10 0 66 +52 27 43 9 26 87 10 0 46 +53 37 31 14 75 124 10 0 26 +54 57 29 -9 118 171 10 73 0 +55 63 23 -7 111 170 10 2 0 +56 53 12 6 106 163 0 0 103 +57 32 12 7 77 134 0 0 105 +58 36 26 -12 147 210 10 97 0 +59 21 24 28 17 100 10 0 38 +60 17 34 -12 134 199 10 18 0 +61 12 24 -26 55 106 10 5 0 +62 24 58 19 30 95 10 0 63 +63 27 69 -19 34 103 10 62 0 +64 15 77 9 48 107 10 0 32 +65 62 77 20 49 113 10 0 1 +66 49 73 -10 104 159 10 51 0 +67 67 5 25 59 116 10 0 41 +68 56 39 -13 117 176 10 3 0 +69 37 47 6 23 86 10 0 30 +70 37 56 -9 123 198 10 20 0 +71 57 68 -16 54 109 10 27 0 +72 47 16 25 22 96 10 0 40 +73 44 17 9 56 109 10 0 54 +74 46 13 8 123 184 10 0 4 +75 49 11 -29 45 102 10 23 0 +76 49 42 13 52 103 10 0 80 +77 53 43 14 136 200 10 0 50 +78 61 52 -9 71 130 10 29 0 +79 57 48 -16 72 121 10 28 0 +80 56 37 -13 135 198 10 76 0 +81 55 54 26 78 119 10 0 24 +82 15 47 16 29 90 10 0 47 +83 14 37 11 21 89 10 0 16 +84 11 31 7 81 130 10 0 100 +85 16 22 41 70 121 10 0 94 +86 4 18 35 74 123 10 0 91 +87 28 18 26 79 116 10 0 43 +88 26 52 9 50 107 10 0 8 +89 26 35 -2 139 211 10 17 0 +90 31 67 -12 73 126 10 11 0 +91 15 19 -35 132 194 10 86 0 +92 22 22 2 18 88 10 0 42 +93 18 24 -8 129 199 10 37 0 +94 26 27 -41 81 128 10 85 0 +95 25 24 20 14 78 10 0 15 +96 22 27 -3 114 165 10 6 0 +97 25 21 12 115 160 10 0 58 +98 19 21 10 32 93 10 0 13 +99 20 26 9 60 115 0 0 104 +100 18 18 -7 123 195 10 84 0 +101 30 60 -16 107 150 10 10 0 +102 65 55 -14 96 147 10 34 0 +103 53 12 -6 106 163 10 56 0 +104 20 26 -9 60 115 10 99 0 +105 32 12 -7 77 134 10 57 0 +106 6 68 -30 93 132 10 49 0 diff --git a/jsprit-instances/instances/lilim/lr110.txt b/jsprit-instances/instances/lilim/lr110.txt new file mode 100644 index 00000000..7734b956 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr110.txt @@ -0,0 +1,106 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -21 130 201 10 30 0 +2 35 17 7 20 89 10 0 41 +3 55 45 -23 106 135 10 79 0 +4 55 20 -31 71 195 10 39 0 +5 15 30 26 20 107 10 0 61 +6 25 30 3 54 153 10 0 94 +7 20 50 5 66 105 10 0 18 +8 10 43 -16 61 138 10 82 0 +9 55 60 16 53 150 10 0 51 +10 30 60 16 101 156 0 0 101 +11 20 65 -19 33 152 10 62 0 +12 50 35 19 38 97 10 0 29 +13 30 25 -7 70 208 10 43 0 +14 15 10 20 32 137 10 0 86 +15 30 5 8 30 154 10 0 42 +16 10 20 -11 54 105 10 83 0 +17 5 30 2 51 189 10 0 60 +18 20 40 -5 77 106 10 7 0 +19 15 60 17 53 108 10 0 49 +20 45 65 -27 109 152 10 31 0 +21 45 20 11 37 96 10 0 72 +22 45 10 18 59 144 10 0 26 +23 55 5 29 36 155 10 0 55 +24 65 35 -18 118 190 10 54 0 +25 65 20 -25 47 186 10 67 0 +26 45 30 -18 117 156 10 22 0 +27 35 40 16 5 156 10 0 65 +28 41 37 16 8 79 10 0 68 +29 64 42 -19 37 98 10 12 0 +30 40 60 21 28 123 10 0 1 +31 31 52 27 24 85 10 0 20 +32 35 69 23 116 175 0 0 102 +33 53 52 11 24 179 0 0 103 +34 65 55 -26 100 143 10 81 0 +35 63 65 -15 50 178 10 71 0 +36 2 60 -27 41 178 10 47 0 +37 20 20 8 117 160 10 0 93 +38 5 5 -18 42 145 10 44 0 +39 60 12 31 33 186 10 0 4 +40 40 25 -9 51 128 10 73 0 +41 42 7 -7 44 159 10 2 0 +42 24 12 -8 25 172 10 15 0 +43 23 3 7 115 158 10 0 13 +44 11 14 18 31 138 10 0 38 +45 6 38 16 29 189 10 0 89 +46 2 48 1 93 150 10 0 48 +47 8 56 27 34 116 10 0 36 +48 13 52 -1 125 192 10 46 0 +49 6 68 -17 93 132 10 19 0 +50 47 47 13 105 152 10 0 80 +51 49 58 -16 66 119 10 9 0 +52 27 43 9 25 88 10 0 88 +53 37 31 -8 62 137 10 74 0 +54 57 29 18 121 168 10 0 24 +55 63 23 -29 70 189 10 23 0 +56 53 12 -18 81 188 10 75 0 +57 32 12 7 78 133 10 0 58 +58 36 26 -7 79 210 10 57 0 +59 21 24 28 17 123 10 0 87 +60 17 34 -2 130 201 10 17 0 +61 12 24 -26 59 102 10 5 0 +62 24 58 19 25 164 10 0 11 +63 27 69 10 34 112 10 0 90 +64 15 77 9 46 165 10 0 70 +65 62 77 -16 49 170 10 27 0 +66 49 73 -6 77 179 10 69 0 +67 67 5 25 43 150 10 0 25 +68 56 39 -16 82 198 10 28 0 +69 37 47 6 12 142 10 0 66 +70 37 56 -9 21 198 10 64 0 +71 57 68 15 57 106 10 0 35 +72 47 16 -11 22 110 10 21 0 +73 44 17 9 60 105 10 0 40 +74 46 13 8 73 195 10 0 53 +75 49 11 18 46 101 10 0 56 +76 49 42 13 36 119 10 0 78 +77 53 43 14 65 200 0 0 104 +78 61 52 -13 43 158 10 76 0 +79 57 48 23 58 135 10 0 3 +80 56 37 -13 69 198 10 50 0 +81 55 54 26 87 110 10 0 34 +82 15 47 16 28 91 10 0 8 +83 14 37 11 21 97 10 0 16 +84 11 31 -20 68 143 10 95 0 +85 16 22 -2 74 117 10 92 0 +86 4 18 -20 79 118 10 14 0 +87 28 18 -28 84 111 10 59 0 +88 26 52 -9 24 133 10 52 0 +89 26 35 -16 128 211 10 45 0 +90 31 67 -10 76 123 10 63 0 +91 15 19 -11 130 194 10 96 0 +92 22 22 2 18 181 10 0 85 +93 18 24 -8 41 199 10 37 0 +94 26 27 -3 88 121 10 6 0 +95 25 24 20 14 83 10 0 84 +96 22 27 11 119 160 10 0 91 +97 25 21 12 122 153 10 0 100 +98 19 21 -9 32 93 10 99 0 +99 20 26 9 38 137 10 0 98 +100 18 18 -12 28 195 10 97 0 +101 30 60 -16 101 156 10 10 0 +102 35 69 -23 116 175 10 32 0 +103 53 52 -11 24 179 10 33 0 +104 53 43 -14 65 200 10 77 0 diff --git a/jsprit-instances/instances/lilim/lr111.txt b/jsprit-instances/instances/lilim/lr111.txt new file mode 100644 index 00000000..c884dfb7 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr111.txt @@ -0,0 +1,110 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 10 15 204 10 0 81 +2 35 17 7 18 202 10 0 22 +3 55 45 -9 54 187 10 29 0 +4 55 20 -13 138 169 10 76 0 +5 15 30 -35 20 199 10 86 0 +6 25 30 -8 76 131 10 37 0 +7 20 50 5 21 170 10 0 36 +8 10 43 9 87 112 0 0 105 +9 55 60 16 88 115 10 0 50 +10 30 60 -19 107 150 10 62 0 +11 20 65 12 57 86 10 0 20 +12 50 35 -9 15 192 10 40 0 +13 30 25 -27 147 180 10 94 0 +14 15 10 20 32 187 10 0 16 +15 30 5 8 50 81 10 0 72 +16 10 20 -20 29 139 10 14 0 +17 5 30 2 124 189 10 0 60 +18 20 40 12 47 136 10 0 45 +19 15 60 17 32 146 10 0 47 +20 45 65 -12 79 182 10 11 0 +21 45 20 11 18 195 10 0 58 +22 45 10 -7 76 127 10 2 0 +23 55 5 29 58 87 10 0 55 +24 65 35 -6 58 190 10 25 0 +25 65 20 6 153 186 10 0 24 +26 45 30 -18 58 208 10 54 0 +27 35 40 16 8 75 0 0 101 +28 41 37 16 6 136 10 0 79 +29 64 42 9 29 150 10 0 3 +30 40 60 21 49 102 10 0 51 +31 31 52 -9 17 198 10 52 0 +32 35 69 -10 67 186 10 63 0 +33 53 52 11 24 92 10 0 71 +34 65 55 -8 36 183 10 35 0 +35 63 65 8 116 178 10 0 34 +36 2 60 -5 41 112 10 7 0 +37 20 20 8 42 198 10 0 6 +38 5 5 -18 74 101 10 44 0 +39 60 12 31 33 110 10 0 80 +40 40 25 9 65 114 10 0 12 +41 42 7 -7 72 131 10 43 0 +42 24 12 -20 25 91 10 95 0 +43 23 3 7 82 185 10 0 41 +44 11 14 18 59 88 10 0 38 +45 6 38 -12 29 99 10 18 0 +46 2 48 1 63 180 10 0 48 +47 8 56 -17 34 176 10 19 0 +48 13 52 -1 27 192 10 46 0 +49 6 68 -9 93 132 10 64 0 +50 47 47 -16 41 203 10 9 0 +51 49 58 -21 36 149 10 30 0 +52 27 43 9 11 195 10 0 31 +53 37 31 -6 87 112 10 69 0 +54 57 29 18 90 197 10 0 26 +55 63 23 -29 126 155 10 23 0 +56 53 12 -8 106 163 10 74 0 +57 32 12 7 48 163 0 0 102 +58 36 26 -11 178 210 10 21 0 +59 21 24 28 17 202 10 0 97 +60 17 34 -2 70 201 10 17 0 +61 12 24 13 29 132 10 0 96 +62 24 58 19 46 79 10 0 10 +63 27 69 10 34 172 10 0 32 +64 15 77 9 48 107 10 0 49 +65 62 77 20 49 113 10 0 66 +66 49 73 -20 104 159 10 65 0 +67 67 5 -18 73 102 10 75 0 +68 56 39 -3 117 176 10 78 0 +69 37 47 6 39 70 10 0 53 +70 37 56 5 123 198 0 0 104 +71 57 68 -11 39 148 10 33 0 +72 47 16 -8 22 197 10 15 0 +73 44 17 9 30 135 0 0 108 +74 46 13 8 138 169 10 0 56 +75 49 11 18 27 192 10 0 67 +76 49 42 13 65 90 10 0 4 +77 53 43 14 168 199 0 0 103 +78 61 52 3 71 130 10 0 68 +79 57 48 -16 84 109 10 28 0 +80 56 37 -31 135 198 10 39 0 +81 55 54 -10 57 140 10 1 0 +82 15 47 16 23 196 0 0 107 +83 14 37 11 21 198 10 0 91 +84 11 31 7 93 118 10 0 85 +85 16 22 -7 23 177 10 84 0 +86 4 18 35 49 148 10 0 5 +87 28 18 -9 88 107 10 99 0 +88 26 52 9 50 107 10 0 90 +89 26 35 15 68 211 0 0 106 +90 31 67 -9 46 153 10 88 0 +91 15 19 -11 25 194 10 83 0 +92 22 22 2 18 53 10 0 98 +93 18 24 -17 129 199 10 100 0 +94 26 27 27 35 174 10 0 13 +95 25 24 20 14 205 10 0 42 +96 22 27 -13 51 204 10 61 0 +97 25 21 -28 92 183 10 59 0 +98 19 21 -2 21 198 10 92 0 +99 20 26 9 74 101 10 0 87 +100 18 18 17 159 195 10 0 93 +101 35 40 -16 8 75 10 27 0 +102 32 12 -7 48 163 10 57 0 +103 53 43 -14 168 199 10 77 0 +104 37 56 -5 123 198 10 70 0 +105 10 43 -9 87 112 10 8 0 +106 26 35 -15 68 211 10 89 0 +107 15 47 -16 23 196 10 82 0 +108 44 17 -9 30 135 10 73 0 diff --git a/jsprit-instances/instances/lilim/lr112.txt b/jsprit-instances/instances/lilim/lr112.txt new file mode 100644 index 00000000..4b398d2c --- /dev/null +++ b/jsprit-instances/instances/lilim/lr112.txt @@ -0,0 +1,108 @@ +25 200 1 +0 35 35 0 0 230 0 0 0 +1 41 49 -20 73 204 10 65 0 +2 35 17 7 18 147 10 0 22 +3 55 45 -9 76 165 10 29 0 +4 55 20 -31 73 195 10 39 0 +5 15 30 26 20 167 10 0 38 +6 25 30 3 49 158 10 0 83 +7 20 50 5 36 135 10 0 47 +8 10 43 -16 50 149 10 82 0 +9 55 60 16 47 156 10 0 50 +10 30 60 16 85 172 10 0 70 +11 20 65 -19 33 152 10 62 0 +12 50 35 -11 15 133 10 21 0 +13 30 25 23 79 208 10 0 58 +14 15 10 20 32 187 10 0 91 +15 30 5 8 30 152 10 0 42 +16 10 20 19 29 139 10 0 96 +17 5 30 -12 60 189 10 18 0 +18 20 40 12 47 136 10 0 17 +19 15 60 17 32 146 10 0 63 +20 45 65 9 79 182 0 0 105 +21 45 20 11 18 136 10 0 12 +22 45 10 -7 50 153 10 2 0 +23 55 5 -5 36 155 10 41 0 +24 65 35 -9 58 190 10 73 0 +25 65 20 6 56 186 10 0 54 +26 45 30 -9 87 186 10 40 0 +27 35 40 16 5 140 10 0 31 +28 41 37 16 6 136 10 0 78 +29 64 42 9 29 150 10 0 3 +30 40 60 21 25 132 10 0 51 +31 31 52 -16 17 138 10 27 0 +32 35 69 -9 67 186 10 64 0 +33 53 52 11 24 161 10 0 68 +34 65 55 -13 70 173 10 76 0 +35 63 65 8 54 178 10 0 66 +36 2 60 5 41 178 10 0 49 +37 20 20 -18 87 190 10 44 0 +38 5 5 -26 42 153 10 5 0 +39 60 12 31 33 186 10 0 4 +40 40 25 9 40 139 10 0 26 +41 42 7 5 43 160 10 0 23 +42 24 12 -8 25 158 10 15 0 +43 23 3 7 82 185 10 0 97 +44 11 14 18 31 144 10 0 37 +45 6 38 16 29 169 10 0 60 +46 2 48 -9 63 180 10 88 0 +47 8 56 -5 34 176 10 7 0 +48 13 52 36 65 192 0 0 104 +49 6 68 -5 73 152 10 36 0 +50 47 47 -16 75 182 10 9 0 +51 49 58 -21 36 149 10 30 0 +52 27 43 9 11 133 10 0 90 +53 37 31 14 51 148 10 0 55 +54 57 29 -6 90 197 10 25 0 +55 63 23 -14 69 189 10 53 0 +56 53 12 -25 76 190 10 72 0 +57 32 12 -10 48 163 10 98 0 +58 36 26 -23 84 210 10 13 0 +59 21 24 28 17 183 10 0 89 +60 17 34 -16 70 201 10 45 0 +61 12 24 13 29 132 10 0 86 +62 24 58 19 25 154 10 0 11 +63 27 69 -17 34 172 10 19 0 +64 15 77 9 46 165 10 0 32 +65 62 77 20 49 170 10 0 1 +66 49 73 -8 68 179 10 35 0 +67 67 5 -18 43 156 10 75 0 +68 56 39 -11 80 198 10 33 0 +69 37 47 6 12 137 10 0 77 +70 37 56 -16 48 198 10 10 0 +71 57 68 -23 39 148 10 79 0 +72 47 16 25 22 170 10 0 56 +73 44 17 9 30 135 10 0 24 +74 46 13 8 74 195 0 0 101 +75 49 11 18 27 141 10 0 67 +76 49 42 13 27 128 10 0 34 +77 53 43 -6 72 200 10 69 0 +78 61 52 -16 42 159 10 28 0 +79 57 48 23 47 146 10 0 71 +80 56 37 6 73 198 0 0 103 +81 55 54 26 57 140 0 0 106 +82 15 47 16 23 146 10 0 8 +83 14 37 -3 21 157 10 6 0 +84 11 31 -27 57 154 10 94 0 +85 16 22 41 44 147 10 0 93 +86 4 18 -13 49 148 10 61 0 +87 28 18 -2 61 134 10 92 0 +88 26 52 9 21 136 10 0 46 +89 26 35 -28 68 211 10 59 0 +90 31 67 -9 46 153 10 52 0 +91 15 19 -20 70 194 10 14 0 +92 22 22 2 18 159 10 0 87 +93 18 24 -41 60 199 10 85 0 +94 26 27 27 58 151 10 0 84 +95 25 24 20 14 143 10 0 99 +96 22 27 -19 89 190 10 16 0 +97 25 21 -7 92 183 10 43 0 +98 19 21 10 21 142 10 0 57 +99 20 26 -20 33 142 10 95 0 +100 18 18 17 51 195 0 0 102 +101 46 13 -8 74 195 10 74 0 +102 18 18 -17 51 195 10 100 0 +103 56 37 -6 73 198 10 80 0 +104 13 52 -36 65 192 10 48 0 +105 45 65 -9 79 182 10 20 0 +106 55 54 -26 57 140 10 81 0 diff --git a/jsprit-instances/instances/lilim/lr201.txt b/jsprit-instances/instances/lilim/lr201.txt new file mode 100644 index 00000000..beac816c --- /dev/null +++ b/jsprit-instances/instances/lilim/lr201.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -9 707 848 10 20 0 +2 35 17 7 143 282 10 0 72 +3 55 45 -21 527 584 10 30 0 +4 55 20 -8 678 801 10 74 0 +5 15 30 26 34 209 10 0 7 +6 25 30 -28 415 514 10 59 0 +7 20 50 -26 331 410 10 5 0 +8 10 43 9 404 481 10 0 18 +9 55 60 -6 400 497 10 69 0 +10 30 60 16 577 632 10 0 70 +11 20 65 -16 206 325 10 82 0 +12 50 35 19 228 345 10 0 71 +13 30 25 -7 690 827 10 43 0 +14 15 10 20 32 243 10 0 99 +15 30 5 8 175 300 10 0 97 +16 10 20 19 272 373 10 0 58 +17 5 30 -30 733 870 10 49 0 +18 20 40 -9 377 434 10 8 0 +19 15 60 17 269 378 10 0 62 +20 45 65 9 581 666 10 0 1 +21 45 20 11 214 331 10 0 56 +22 45 10 18 409 494 10 0 55 +23 55 5 29 206 325 10 0 41 +24 65 35 -36 704 847 10 68 0 +25 65 20 6 817 956 0 0 101 +26 45 30 -26 588 667 10 87 0 +27 35 40 -9 104 255 10 52 0 +28 41 37 16 114 255 10 0 79 +29 64 42 9 190 313 10 0 81 +30 40 60 21 259 354 10 0 3 +31 31 52 27 152 275 10 0 78 +32 35 69 -13 660 777 10 50 0 +33 53 52 11 45 200 10 0 63 +34 65 55 -13 529 614 10 76 0 +35 63 65 -25 686 813 10 66 0 +36 2 60 -27 41 208 10 47 0 +37 20 20 8 606 693 10 0 100 +38 5 5 16 302 405 10 0 96 +39 60 12 31 33 224 10 0 67 +40 40 25 9 360 437 10 0 53 +41 42 7 -29 396 511 10 23 0 +42 24 12 -2 25 172 10 92 0 +43 23 3 7 620 705 10 0 13 +44 11 14 18 233 340 10 0 86 +45 6 38 16 29 189 10 0 64 +46 2 48 -9 515 628 10 88 0 +47 8 56 27 85 250 10 0 36 +48 13 52 36 773 906 10 0 60 +49 6 68 30 501 540 10 0 17 +50 47 47 13 547 642 10 0 32 +51 49 58 -20 348 453 10 65 0 +52 27 43 9 174 299 10 0 27 +53 37 31 -9 414 489 10 40 0 +54 57 29 -9 641 734 10 73 0 +55 63 23 -18 620 739 10 22 0 +56 53 12 -11 585 692 10 21 0 +57 32 12 -18 421 530 10 75 0 +58 36 26 -19 849 980 10 16 0 +59 21 24 28 17 229 10 0 6 +60 17 34 -36 721 862 10 48 0 +61 12 24 -10 290 377 10 98 0 +62 24 58 -17 163 302 10 19 0 +63 27 69 -11 34 191 10 33 0 +64 15 77 -16 214 333 10 45 0 +65 62 77 20 49 188 10 0 51 +66 49 73 25 592 693 10 0 35 +67 67 5 -31 294 401 10 39 0 +68 56 39 36 637 752 10 0 24 +69 37 47 6 162 293 10 0 9 +70 37 56 -16 788 968 10 10 0 +71 57 68 -19 268 367 10 12 0 +72 47 16 -7 31 208 10 2 0 +73 44 17 9 308 399 10 0 54 +74 46 13 8 681 802 10 0 4 +75 49 11 18 236 345 10 0 57 +76 49 42 13 290 373 10 0 34 +77 53 43 -6 817 952 10 80 0 +78 61 52 -27 384 499 10 31 0 +79 57 48 -16 388 465 10 28 0 +80 56 37 6 839 968 10 0 77 +81 55 54 -9 411 456 10 29 0 +82 15 47 16 162 289 10 0 11 +83 14 37 11 96 249 10 0 90 +84 11 31 7 436 511 0 0 102 +85 16 22 -20 376 461 10 95 0 +86 4 18 -18 388 465 10 44 0 +87 28 18 26 420 447 10 0 26 +88 26 52 9 279 388 10 0 46 +89 26 35 -22 755 920 10 93 0 +90 31 67 -11 392 487 10 83 0 +91 15 19 -27 739 866 10 94 0 +92 22 22 2 18 181 10 0 42 +93 18 24 22 811 969 10 0 89 +94 26 27 27 436 503 10 0 91 +95 25 24 20 92 231 10 0 85 +96 22 27 -16 607 690 10 38 0 +97 25 21 -8 612 673 10 15 0 +98 19 21 10 183 306 10 0 61 +99 20 26 -20 333 432 10 14 0 +100 18 18 -8 798 965 10 37 0 +101 65 20 -6 817 956 10 25 0 +102 11 31 -7 436 511 10 84 0 diff --git a/jsprit-instances/instances/lilim/lr202.txt b/jsprit-instances/instances/lilim/lr202.txt new file mode 100644 index 00000000..9b845103 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr202.txt @@ -0,0 +1,102 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -25 0 974 10 66 0 +2 35 17 7 0 972 10 0 43 +3 55 45 13 0 967 10 0 100 +4 55 20 -12 678 801 10 97 0 +5 15 30 -19 0 969 10 16 0 +6 25 30 -35 415 514 10 86 0 +7 20 50 -9 0 968 10 64 0 +8 10 43 9 404 481 10 0 55 +9 55 60 16 400 497 10 0 90 +10 30 60 -15 577 632 10 71 0 +11 20 65 12 206 325 10 0 51 +12 50 35 19 0 975 10 0 26 +13 30 25 23 690 827 10 0 60 +14 15 10 20 32 243 10 0 44 +15 30 5 -41 175 300 10 85 0 +16 10 20 19 272 373 10 0 5 +17 5 30 -11 733 870 10 21 0 +18 20 40 -16 377 434 10 38 0 +19 15 60 17 269 378 10 0 81 +20 45 65 -5 581 666 10 36 0 +21 45 20 11 0 971 10 0 17 +22 45 10 -6 409 494 10 69 0 +23 55 5 -11 206 325 10 96 0 +24 65 35 -2 704 847 10 92 0 +25 65 20 -6 817 956 10 56 0 +26 45 30 -19 0 978 10 12 0 +27 35 40 -9 104 255 10 29 0 +28 41 37 16 114 255 10 0 37 +29 64 42 9 190 313 10 0 27 +30 40 60 21 259 354 10 0 49 +31 31 52 27 0 972 10 0 52 +32 35 69 -16 660 777 10 45 0 +33 53 52 11 45 200 10 0 67 +34 65 55 14 0 953 10 0 53 +35 63 65 -1 686 813 10 46 0 +36 2 60 5 41 208 10 0 20 +37 20 20 -16 0 968 10 28 0 +38 5 5 16 302 405 10 0 18 +39 60 12 31 33 224 10 0 99 +40 40 25 9 360 437 10 0 74 +41 42 7 -7 396 511 10 57 0 +42 24 12 5 25 172 10 0 54 +43 23 3 -7 620 705 10 2 0 +44 11 14 -20 233 340 10 14 0 +45 6 38 16 29 189 10 0 32 +46 2 48 1 515 628 10 0 35 +47 8 56 27 85 250 10 0 63 +48 13 52 36 0 962 10 0 68 +49 6 68 -21 501 540 10 30 0 +50 47 47 13 0 973 10 0 65 +51 49 58 -12 348 453 10 11 0 +52 27 43 -27 0 978 10 31 0 +53 37 31 -14 414 489 10 34 0 +54 57 29 -5 641 734 10 42 0 +55 63 23 -9 620 739 10 8 0 +56 53 12 6 585 692 10 0 25 +57 32 12 7 421 530 10 0 41 +58 36 26 -18 849 980 10 75 0 +59 21 24 28 0 972 10 0 91 +60 17 34 -23 721 862 10 13 0 +61 12 24 13 290 377 10 0 80 +62 24 58 -11 163 302 10 83 0 +63 27 69 -27 34 191 10 47 0 +64 15 77 9 214 333 10 0 7 +65 62 77 -13 49 188 10 50 0 +66 49 73 25 592 693 10 0 1 +67 67 5 -11 294 401 10 33 0 +68 56 39 -36 637 752 10 48 0 +69 37 47 6 162 293 10 0 22 +70 37 56 -9 788 968 10 88 0 +71 57 68 15 268 367 10 0 10 +72 47 16 25 0 967 10 0 93 +73 44 17 -13 308 399 10 76 0 +74 46 13 -9 681 802 10 40 0 +75 49 11 18 0 962 10 0 58 +76 49 42 13 290 373 10 0 73 +77 53 43 -16 817 952 10 82 0 +78 61 52 3 384 499 10 0 79 +79 57 48 -3 388 465 10 78 0 +80 56 37 -13 839 968 10 61 0 +81 55 54 -17 411 456 10 19 0 +82 15 47 16 0 966 10 0 77 +83 14 37 11 0 968 10 0 62 +84 11 31 -10 436 511 10 98 0 +85 16 22 41 0 966 10 0 15 +86 4 18 35 388 465 10 0 6 +87 28 18 26 420 447 10 0 89 +88 26 52 9 279 388 10 0 70 +89 26 35 -26 755 920 10 87 0 +90 31 67 -16 392 487 10 9 0 +91 15 19 -28 0 964 10 59 0 +92 22 22 2 18 181 10 0 24 +93 18 24 -25 811 969 10 72 0 +94 26 27 27 0 977 10 0 95 +95 25 24 -27 0 975 10 94 0 +96 22 27 11 0 974 10 0 23 +97 25 21 12 612 673 10 0 4 +98 19 21 10 0 968 10 0 84 +99 20 26 -31 333 432 10 39 0 +100 18 18 -13 798 965 10 3 0 diff --git a/jsprit-instances/instances/lilim/lr203.txt b/jsprit-instances/instances/lilim/lr203.txt new file mode 100644 index 00000000..1451e493 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr203.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 10 0 974 10 0 6 +2 35 17 7 0 972 10 0 58 +3 55 45 13 0 967 10 0 68 +4 55 20 -26 678 801 10 87 0 +5 15 30 -16 0 969 10 38 0 +6 25 30 -10 415 514 10 1 0 +7 20 50 -25 0 968 10 66 0 +8 10 43 -7 404 481 10 84 0 +9 55 60 16 400 497 0 0 101 +10 30 60 16 577 632 10 0 32 +11 20 65 12 206 325 10 0 13 +12 50 35 -21 0 975 10 30 0 +13 30 25 -12 690 827 10 11 0 +14 15 10 -20 0 957 10 65 0 +15 30 5 8 175 300 10 0 67 +16 10 20 -11 0 960 10 96 0 +17 5 30 -36 733 870 10 48 0 +18 20 40 12 0 974 10 0 83 +19 15 60 17 0 957 10 0 90 +20 45 65 9 0 958 10 0 98 +21 45 20 -25 0 971 10 72 0 +22 45 10 -7 409 494 10 43 0 +23 55 5 29 206 325 10 0 53 +24 65 35 -6 0 960 10 25 0 +25 65 20 6 817 956 10 0 24 +26 45 30 -5 0 978 10 36 0 +27 35 40 16 104 255 10 0 37 +28 41 37 -5 0 983 10 42 0 +29 64 42 -19 0 960 10 62 0 +30 40 60 21 259 354 10 0 12 +31 31 52 27 0 972 10 0 35 +32 35 69 -16 0 956 10 10 0 +33 53 52 11 45 200 10 0 71 +34 65 55 -1 0 953 10 46 0 +35 63 65 -27 686 813 10 31 0 +36 2 60 5 41 208 10 0 26 +37 20 20 -16 0 968 10 27 0 +38 5 5 16 302 405 10 0 5 +39 60 12 -20 33 224 10 95 0 +40 40 25 9 360 437 10 0 41 +41 42 7 -9 396 511 10 40 0 +42 24 12 5 25 172 10 0 28 +43 23 3 7 0 955 10 0 22 +44 11 14 -41 233 340 10 85 0 +45 6 38 -3 29 189 10 60 0 +46 2 48 1 0 954 10 0 34 +47 8 56 27 0 955 10 0 93 +48 13 52 36 0 962 10 0 17 +49 6 68 -10 501 540 10 51 0 +50 47 47 13 0 973 10 0 81 +51 49 58 10 0 963 10 0 49 +52 27 43 9 0 978 10 0 64 +53 37 31 -29 414 489 10 23 0 +54 57 29 18 0 967 10 0 80 +55 63 23 -9 620 739 10 73 0 +56 53 12 6 585 692 10 0 74 +57 32 12 7 0 966 10 0 77 +58 36 26 -7 849 980 10 2 0 +59 21 24 -6 0 972 10 69 0 +60 17 34 3 0 971 10 0 45 +61 12 24 13 0 964 10 0 97 +62 24 58 19 163 302 10 0 29 +63 27 69 10 0 955 10 0 82 +64 15 77 -9 214 333 10 52 0 +65 62 77 20 49 188 10 0 14 +66 49 73 25 592 693 10 0 7 +67 67 5 -8 294 401 10 15 0 +68 56 39 -13 637 752 10 3 0 +69 37 47 6 162 293 10 0 59 +70 37 56 -35 788 968 10 86 0 +71 57 68 -11 0 950 10 33 0 +72 47 16 25 0 967 10 0 21 +73 44 17 9 0 969 10 0 55 +74 46 13 -6 681 802 10 56 0 +75 49 11 -27 0 962 10 94 0 +76 49 42 -9 290 373 10 88 0 +77 53 43 -7 817 952 10 57 0 +78 61 52 -23 384 499 10 79 0 +79 57 48 23 388 465 10 0 78 +80 56 37 -18 839 968 10 54 0 +81 55 54 -13 0 962 10 50 0 +82 15 47 -10 0 966 10 63 0 +83 14 37 -12 0 968 10 18 0 +84 11 31 7 436 511 10 0 8 +85 16 22 41 0 966 10 0 44 +86 4 18 35 0 954 10 0 70 +87 28 18 26 420 447 10 0 4 +88 26 52 9 279 388 10 0 76 +89 26 35 15 0 981 10 0 91 +90 31 67 -17 0 957 10 19 0 +91 15 19 -15 0 964 10 89 0 +92 22 22 2 18 181 0 0 102 +93 18 24 -27 811 969 10 47 0 +94 26 27 27 0 977 10 0 75 +95 25 24 20 0 975 10 0 39 +96 22 27 11 0 974 10 0 16 +97 25 21 -13 0 972 10 61 0 +98 19 21 -9 0 968 10 20 0 +99 20 26 9 333 432 10 0 100 +100 18 18 -9 798 965 10 99 0 +101 55 60 -16 400 497 10 9 0 +102 22 22 -2 18 181 10 92 0 diff --git a/jsprit-instances/instances/lilim/lr204.txt b/jsprit-instances/instances/lilim/lr204.txt new file mode 100644 index 00000000..f8c5faa1 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr204.txt @@ -0,0 +1,102 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -18 0 974 10 44 0 +2 35 17 -20 0 972 10 65 0 +3 55 45 -9 0 967 10 8 0 +4 55 20 -14 678 801 10 34 0 +5 15 30 -20 0 969 10 95 0 +6 25 30 -28 0 978 10 59 0 +7 20 50 5 0 968 10 0 31 +8 10 43 9 404 481 10 0 3 +9 55 60 16 400 497 10 0 21 +10 30 60 -8 0 964 10 15 0 +11 20 65 12 206 325 10 0 67 +12 50 35 19 0 975 10 0 35 +13 30 25 -9 690 827 10 29 0 +14 15 10 -2 0 957 10 92 0 +15 30 5 8 175 300 10 0 10 +16 10 20 19 0 960 10 0 61 +17 5 30 2 0 959 10 0 46 +18 20 40 12 0 974 10 0 37 +19 15 60 17 0 957 10 0 88 +20 45 65 -14 0 958 10 53 0 +21 45 20 -16 0 971 10 9 0 +22 45 10 18 0 963 10 0 49 +23 55 5 -5 206 325 10 42 0 +24 65 35 -16 0 960 10 27 0 +25 65 20 -7 817 956 10 57 0 +26 45 30 -36 0 978 10 68 0 +27 35 40 16 0 985 10 0 24 +28 41 37 16 0 983 10 0 97 +29 64 42 9 0 960 10 0 13 +30 40 60 -16 0 964 10 45 0 +31 31 52 -5 0 972 10 7 0 +32 35 69 23 0 956 10 0 58 +33 53 52 -10 0 965 10 63 0 +34 65 55 14 0 953 10 0 4 +35 63 65 -19 0 948 10 12 0 +36 2 60 5 0 948 10 0 64 +37 20 20 -12 0 968 10 18 0 +38 5 5 16 302 405 10 0 60 +39 60 12 -6 0 956 10 69 0 +40 40 25 -18 0 978 10 54 0 +41 42 7 5 0 961 10 0 43 +42 24 12 5 0 964 10 0 23 +43 23 3 -5 0 955 10 41 0 +44 11 14 18 233 340 10 0 1 +45 6 38 16 0 960 10 0 30 +46 2 48 -2 0 954 10 17 0 +47 8 56 -7 0 955 10 84 0 +48 13 52 36 0 962 10 0 93 +49 6 68 -18 0 946 10 22 0 +50 47 47 -11 0 973 10 83 0 +51 49 58 10 0 963 10 0 55 +52 27 43 9 0 978 10 0 81 +53 37 31 14 414 489 10 0 20 +54 57 29 18 0 967 10 0 40 +55 63 23 -10 620 739 10 51 0 +56 53 12 -27 0 960 10 94 0 +57 32 12 7 0 966 10 0 25 +58 36 26 -23 849 980 10 32 0 +59 21 24 28 0 972 10 0 6 +60 17 34 -16 0 971 10 38 0 +61 12 24 -19 0 964 10 16 0 +62 24 58 19 163 302 10 0 79 +63 27 69 10 0 955 10 0 33 +64 15 77 -5 0 943 10 36 0 +65 62 77 20 0 940 10 0 2 +66 49 73 25 0 949 10 0 71 +67 67 5 -12 294 401 10 11 0 +68 56 39 36 0 968 10 0 26 +69 37 47 6 162 293 10 0 39 +70 37 56 5 0 968 10 0 80 +71 57 68 -25 0 950 10 66 0 +72 47 16 -16 0 967 10 82 0 +73 44 17 9 0 969 10 0 96 +74 46 13 -3 681 802 10 78 0 +75 49 11 18 0 962 10 0 90 +76 49 42 13 290 373 10 0 100 +77 53 43 -26 817 952 10 87 0 +78 61 52 3 0 958 10 0 74 +79 57 48 -19 388 465 10 62 0 +80 56 37 -5 0 968 10 70 0 +81 55 54 -9 0 962 10 52 0 +82 15 47 16 0 966 10 0 72 +83 14 37 11 0 968 10 0 50 +84 11 31 7 436 511 10 0 47 +85 16 22 -10 0 966 10 98 0 +86 4 18 35 0 954 10 0 99 +87 28 18 26 420 447 10 0 77 +88 26 52 -17 0 970 10 19 0 +89 26 35 -1 0 981 10 91 0 +90 31 67 -18 0 957 10 75 0 +91 15 19 1 0 964 10 0 89 +92 22 22 2 18 181 10 0 14 +93 18 24 -36 0 969 10 48 0 +94 26 27 27 0 977 10 0 56 +95 25 24 20 0 975 10 0 5 +96 22 27 -9 0 974 10 73 0 +97 25 21 -16 0 972 10 28 0 +98 19 21 10 0 968 10 0 85 +99 20 26 -35 333 432 10 86 0 +100 18 18 -13 798 965 10 76 0 diff --git a/jsprit-instances/instances/lilim/lr205.txt b/jsprit-instances/instances/lilim/lr205.txt new file mode 100644 index 00000000..6a537bf5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr205.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -5 658 898 10 36 0 +2 35 17 -18 93 333 10 75 0 +3 55 45 13 436 676 10 0 50 +4 55 20 -16 620 860 10 82 0 +5 15 30 26 20 260 10 0 53 +6 25 30 3 345 585 10 0 22 +7 20 50 5 251 491 10 0 99 +8 10 43 -29 323 563 10 23 0 +9 55 60 -9 329 569 10 20 0 +10 30 60 16 485 725 10 0 17 +11 20 65 12 146 386 10 0 24 +12 50 35 19 167 407 10 0 66 +13 30 25 -22 639 879 10 93 0 +14 15 10 20 32 272 10 0 16 +15 30 5 -28 118 358 10 59 0 +16 10 20 -20 203 443 10 14 0 +17 5 30 -16 682 922 10 10 0 +18 20 40 12 286 526 10 0 74 +19 15 60 -10 204 444 10 63 0 +20 45 65 9 504 744 10 0 9 +21 45 20 11 153 393 10 0 61 +22 45 10 -3 332 572 10 6 0 +23 55 5 29 146 386 10 0 8 +24 65 35 -12 656 896 10 11 0 +25 65 20 6 716 956 10 0 55 +26 45 30 -23 508 748 10 79 0 +27 35 40 16 60 300 10 0 65 +28 41 37 16 65 305 10 0 76 +29 64 42 9 132 372 10 0 51 +30 40 60 -11 187 427 10 33 0 +31 31 52 27 94 334 10 0 73 +32 35 69 23 599 839 10 0 37 +33 53 52 11 24 264 10 0 30 +34 65 55 -8 452 692 10 35 0 +35 63 65 8 630 870 10 0 34 +36 2 60 5 41 281 10 0 1 +37 20 20 -23 530 770 10 32 0 +38 5 5 -41 234 474 10 85 0 +39 60 12 31 33 273 10 0 67 +40 40 25 -11 279 519 10 83 0 +41 42 7 5 334 574 10 0 43 +42 24 12 -2 25 265 10 92 0 +43 23 3 -5 543 783 10 41 0 +44 11 14 18 167 407 10 0 84 +45 6 38 16 29 269 10 0 57 +46 2 48 -20 452 692 10 95 0 +47 8 56 27 48 288 10 0 62 +48 13 52 36 720 960 10 0 89 +49 6 68 -26 401 641 10 87 0 +50 47 47 -13 475 715 10 3 0 +51 49 58 -9 281 521 10 29 0 +52 27 43 -6 117 357 10 69 0 +53 37 31 -26 332 572 10 5 0 +54 57 29 18 568 808 10 0 80 +55 63 23 -6 560 800 10 25 0 +56 53 12 -9 519 759 10 64 0 +57 32 12 -16 356 596 10 45 0 +58 36 26 -1 740 980 10 91 0 +59 21 24 28 17 257 10 0 15 +60 17 34 3 672 912 10 0 97 +61 12 24 -11 214 454 10 21 0 +62 24 58 -27 113 353 10 47 0 +63 27 69 10 34 274 10 0 19 +64 15 77 9 154 394 10 0 56 +65 62 77 -16 49 289 10 27 0 +66 49 73 -19 523 763 10 12 0 +67 67 5 -31 228 468 10 39 0 +68 56 39 36 575 815 0 0 102 +69 37 47 6 108 348 10 0 52 +70 37 56 -14 728 968 10 77 0 +71 57 68 15 198 438 10 0 78 +72 47 16 25 22 262 10 0 86 +73 44 17 -27 234 474 10 31 0 +74 46 13 -12 622 862 10 18 0 +75 49 11 18 171 411 10 0 2 +76 49 42 -16 212 452 10 28 0 +77 53 43 14 730 970 10 0 70 +78 61 52 -15 322 562 10 71 0 +79 57 48 23 307 547 10 0 26 +80 56 37 -18 728 968 10 54 0 +81 55 54 26 314 554 0 0 101 +82 15 47 16 106 346 10 0 4 +83 14 37 11 53 293 10 0 40 +84 11 31 -18 354 594 10 44 0 +85 16 22 41 299 539 10 0 38 +86 4 18 -25 307 547 10 72 0 +87 28 18 26 314 554 10 0 49 +88 26 52 9 214 454 10 0 94 +89 26 35 -36 718 958 10 48 0 +90 31 67 -10 320 560 10 98 0 +91 15 19 1 683 923 10 0 58 +92 22 22 2 18 258 10 0 42 +93 18 24 22 729 969 10 0 13 +94 26 27 -9 350 590 10 88 0 +95 25 24 20 42 282 10 0 46 +96 22 27 11 529 769 10 0 100 +97 25 21 -3 523 763 10 60 0 +98 19 21 10 125 365 10 0 90 +99 20 26 -5 263 503 10 7 0 +100 18 18 -11 725 965 10 96 0 +101 55 54 -26 314 554 10 81 0 +102 56 39 -36 575 815 10 68 0 diff --git a/jsprit-instances/instances/lilim/lr206.txt b/jsprit-instances/instances/lilim/lr206.txt new file mode 100644 index 00000000..cdc8fcc5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr206.txt @@ -0,0 +1,102 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 10 0 974 10 0 74 +2 35 17 -18 0 972 10 22 0 +3 55 45 13 0 967 10 0 81 +4 55 20 -16 620 860 10 27 0 +5 15 30 26 0 969 10 0 38 +6 25 30 3 345 585 10 0 80 +7 20 50 5 0 968 10 0 93 +8 10 43 9 323 563 10 0 83 +9 55 60 -15 329 569 10 71 0 +10 30 60 16 485 725 10 0 70 +11 20 65 12 146 386 10 0 89 +12 50 35 19 0 975 10 0 51 +13 30 25 -7 639 879 10 84 0 +14 15 10 20 32 272 10 0 98 +15 30 5 -5 118 358 10 36 0 +16 10 20 19 203 443 10 0 58 +17 5 30 -3 682 922 10 60 0 +18 20 40 -2 286 526 10 92 0 +19 15 60 17 204 444 10 0 85 +20 45 65 -9 504 744 10 29 0 +21 45 20 11 0 971 10 0 25 +22 45 10 18 332 572 10 0 2 +23 55 5 29 146 386 10 0 54 +24 65 35 -7 656 896 10 43 0 +25 65 20 -11 716 956 10 21 0 +26 45 30 17 0 978 10 0 67 +27 35 40 16 60 300 10 0 4 +28 41 37 16 65 305 10 0 79 +29 64 42 9 132 372 10 0 20 +30 40 60 -3 187 427 10 90 0 +31 31 52 27 0 972 10 0 52 +32 35 69 -10 599 839 10 63 0 +33 53 52 11 24 264 10 0 78 +34 65 55 14 0 953 10 0 66 +35 63 65 -19 630 870 10 62 0 +36 2 60 5 41 281 10 0 15 +37 20 20 -9 0 968 10 88 0 +38 5 5 -26 234 474 10 5 0 +39 60 12 31 33 273 10 0 95 +40 40 25 9 279 519 10 0 68 +41 42 7 5 334 574 10 0 57 +42 24 12 5 25 265 10 0 100 +43 23 3 7 543 783 10 0 24 +44 11 14 18 167 407 10 0 46 +45 6 38 -16 29 269 10 82 0 +46 2 48 -18 452 692 10 44 0 +47 8 56 27 48 288 10 0 61 +48 13 52 36 0 962 10 0 91 +49 6 68 -28 401 641 10 59 0 +50 47 47 13 0 973 10 0 99 +51 49 58 -19 281 521 10 12 0 +52 27 43 -27 0 978 10 31 0 +53 37 31 -9 332 572 10 73 0 +54 57 29 -29 568 808 10 23 0 +55 63 23 -26 560 800 10 87 0 +56 53 12 -12 519 759 10 97 0 +57 32 12 -5 356 596 10 41 0 +58 36 26 -19 740 980 10 16 0 +59 21 24 28 0 972 10 0 49 +60 17 34 3 672 912 10 0 17 +61 12 24 -27 214 454 10 47 0 +62 24 58 19 113 353 10 0 35 +63 27 69 10 34 274 10 0 32 +64 15 77 -20 154 394 10 65 0 +65 62 77 20 49 289 10 0 64 +66 49 73 -14 523 763 10 34 0 +67 67 5 -17 228 468 10 26 0 +68 56 39 -9 575 815 10 40 0 +69 37 47 6 108 348 10 0 76 +70 37 56 -16 728 968 10 10 0 +71 57 68 15 198 438 10 0 9 +72 47 16 25 0 967 10 0 96 +73 44 17 9 234 474 10 0 53 +74 46 13 -10 622 862 10 1 0 +75 49 11 18 0 962 10 0 77 +76 49 42 -6 212 452 10 69 0 +77 53 43 -18 730 970 10 75 0 +78 61 52 -11 322 562 10 33 0 +79 57 48 -16 307 547 10 28 0 +80 56 37 -3 728 968 10 6 0 +81 55 54 -13 314 554 10 3 0 +82 15 47 16 0 966 10 0 45 +83 14 37 -9 0 968 10 8 0 +84 11 31 7 354 594 10 0 13 +85 16 22 -17 0 966 10 19 0 +86 4 18 35 307 547 10 0 94 +87 28 18 26 314 554 10 0 55 +88 26 52 9 214 454 10 0 37 +89 26 35 -12 718 958 10 11 0 +90 31 67 3 320 560 10 0 30 +91 15 19 -36 0 964 10 48 0 +92 22 22 2 18 258 10 0 18 +93 18 24 -5 729 969 10 7 0 +94 26 27 -35 0 977 10 86 0 +95 25 24 -31 0 975 10 39 0 +96 22 27 -25 0 974 10 72 0 +97 25 21 12 523 763 10 0 56 +98 19 21 -20 0 968 10 14 0 +99 20 26 -13 263 503 10 50 0 +100 18 18 -5 725 965 10 42 0 diff --git a/jsprit-instances/instances/lilim/lr207.txt b/jsprit-instances/instances/lilim/lr207.txt new file mode 100644 index 00000000..fa9c6c75 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr207.txt @@ -0,0 +1,104 @@ +25 1000 0 +0 35 35 0 0 1000 0 0 0 +1 41 49 10 0 974 10 0 90 +2 35 17 -10 0 972 10 51 0 +3 55 45 -6 0 967 10 69 0 +4 55 20 19 620 860 10 0 13 +5 15 30 -13 0 969 10 50 0 +6 25 30 3 345 585 10 0 32 +7 20 50 -10 0 968 10 63 0 +8 10 43 9 323 563 10 0 47 +9 55 60 16 329 569 10 0 72 +10 30 60 16 485 725 10 0 35 +11 20 65 -11 146 386 10 83 0 +12 50 35 -18 0 975 10 54 0 +13 30 25 -19 639 879 10 4 0 +14 15 10 20 0 957 10 0 49 +15 30 5 8 118 358 10 0 38 +16 10 20 19 0 960 10 0 82 +17 5 30 -11 682 922 10 33 0 +18 20 40 -35 0 974 10 86 0 +19 15 60 17 0 957 10 0 66 +20 45 65 9 0 958 10 0 93 +21 45 20 -1 0 971 10 46 0 +22 45 10 -2 332 572 10 92 0 +23 55 5 -26 146 386 10 81 0 +24 65 35 3 0 960 10 0 44 +25 65 20 -18 716 956 10 75 0 +26 45 30 17 0 978 10 0 95 +27 35 40 16 60 300 10 0 94 +28 41 37 16 0 983 10 0 77 +29 64 42 9 0 960 10 0 67 +30 40 60 21 187 427 10 0 97 +31 31 52 -36 0 972 10 48 0 +32 35 69 -3 0 956 10 6 0 +33 53 52 11 24 264 10 0 17 +34 65 55 14 0 953 10 0 37 +35 63 65 -16 630 870 10 10 0 +36 2 60 -3 41 281 10 60 0 +37 20 20 -14 0 968 10 34 0 +38 5 5 -8 234 474 10 15 0 +39 60 12 31 33 273 10 0 84 +40 40 25 9 279 519 10 0 87 +41 42 7 5 334 574 10 0 74 +42 24 12 5 25 265 10 0 57 +43 23 3 7 0 955 10 0 85 +44 11 14 -3 167 407 10 24 0 +45 6 38 16 29 269 10 0 78 +46 2 48 1 0 954 10 0 21 +47 8 56 -9 0 955 10 8 0 +48 13 52 36 0 962 10 0 31 +49 6 68 -20 401 641 10 14 0 +50 47 47 13 0 973 10 0 5 +51 49 58 10 0 963 10 0 2 +52 27 43 9 0 978 10 0 79 +53 37 31 14 332 572 10 0 56 +54 57 29 18 0 967 10 0 12 +55 63 23 2 560 800 0 0 102 +56 53 12 -14 519 759 10 53 0 +57 32 12 -5 0 966 10 42 0 +58 36 26 -19 740 980 10 62 0 +59 21 24 28 0 972 10 0 73 +60 17 34 3 0 971 10 0 36 +61 12 24 13 0 964 10 0 100 +62 24 58 19 113 353 10 0 58 +63 27 69 10 0 955 10 0 7 +64 15 77 9 154 394 10 0 89 +65 62 77 20 49 289 10 0 71 +66 49 73 -17 523 763 10 19 0 +67 67 5 -9 228 468 10 29 0 +68 56 39 -9 575 815 10 88 0 +69 37 47 6 108 348 10 0 3 +70 37 56 -9 728 968 10 99 0 +71 57 68 -20 0 950 10 65 0 +72 47 16 -16 0 967 10 9 0 +73 44 17 -28 0 969 10 59 0 +74 46 13 -5 622 862 10 41 0 +75 49 11 18 0 962 10 0 25 +76 49 42 13 212 452 10 0 80 +77 53 43 -16 730 970 10 28 0 +78 61 52 -16 322 562 10 45 0 +79 57 48 -9 307 547 10 52 0 +80 56 37 -13 728 968 10 76 0 +81 55 54 26 0 962 10 0 23 +82 15 47 -19 0 966 10 16 0 +83 14 37 11 0 968 10 0 11 +84 11 31 -31 354 594 10 39 0 +85 16 22 -7 0 966 10 43 0 +86 4 18 35 0 954 10 0 18 +87 28 18 -9 314 554 10 40 0 +88 26 52 9 214 454 10 0 68 +89 26 35 -9 0 981 10 64 0 +90 31 67 -10 0 957 10 1 0 +91 15 19 1 0 964 0 0 101 +92 22 22 2 18 258 10 0 22 +93 18 24 -9 729 969 10 20 0 +94 26 27 -16 0 977 10 27 0 +95 25 24 -17 0 975 10 26 0 +96 22 27 -10 0 974 10 98 0 +97 25 21 -21 0 972 10 30 0 +98 19 21 10 0 968 10 0 96 +99 20 26 9 263 503 10 0 70 +100 18 18 -13 725 965 10 61 0 +101 15 19 -1 0 964 10 91 0 +102 63 23 -2 560 800 10 55 0 diff --git a/jsprit-instances/instances/lilim/lr208.txt b/jsprit-instances/instances/lilim/lr208.txt new file mode 100644 index 00000000..759a6b72 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr208.txt @@ -0,0 +1,102 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -5 0 974 10 70 0 +2 35 17 -2 0 972 10 92 0 +3 55 45 -16 0 967 10 28 0 +4 55 20 19 620 860 10 0 6 +5 15 30 -7 0 969 10 43 0 +6 25 30 -19 0 978 10 4 0 +7 20 50 5 0 968 10 0 98 +8 10 43 9 323 563 10 0 30 +9 55 60 16 329 569 10 0 71 +10 30 60 16 0 964 10 0 78 +11 20 65 12 146 386 10 0 69 +12 50 35 -5 0 975 10 36 0 +13 30 25 -8 639 879 10 35 0 +14 15 10 -20 0 957 10 95 0 +15 30 5 8 118 358 10 0 86 +16 10 20 -27 0 960 10 94 0 +17 5 30 -16 0 959 10 38 0 +18 20 40 12 0 974 10 0 81 +19 15 60 17 0 957 10 0 89 +20 45 65 9 0 958 10 0 65 +21 45 20 11 0 971 10 0 59 +22 45 10 -5 0 963 10 42 0 +23 55 5 29 146 386 10 0 90 +24 65 35 -16 0 960 10 82 0 +25 65 20 6 716 956 10 0 74 +26 45 30 -6 0 978 10 80 0 +27 35 40 -19 0 985 10 62 0 +28 41 37 16 0 983 10 0 3 +29 64 42 -11 0 960 10 33 0 +30 40 60 -9 0 964 10 8 0 +31 31 52 27 0 972 10 0 79 +32 35 69 -13 0 956 10 61 0 +33 53 52 11 0 965 10 0 29 +34 65 55 14 0 953 10 0 37 +35 63 65 8 0 948 10 0 13 +36 2 60 5 0 948 10 0 12 +37 20 20 -14 0 968 10 34 0 +38 5 5 16 234 474 10 0 17 +39 60 12 31 0 956 10 0 56 +40 40 25 -25 0 978 10 72 0 +41 42 7 5 0 961 10 0 64 +42 24 12 5 0 964 10 0 22 +43 23 3 7 0 955 10 0 5 +44 11 14 -9 167 407 10 99 0 +45 6 38 -26 0 960 10 87 0 +46 2 48 1 0 954 10 0 50 +47 8 56 27 0 955 10 0 77 +48 13 52 36 0 962 10 0 76 +49 6 68 30 0 946 10 0 63 +50 47 47 -1 0 973 10 46 0 +51 49 58 10 0 963 10 0 96 +52 27 43 9 0 978 10 0 53 +53 37 31 -9 332 572 10 52 0 +54 57 29 18 0 967 10 0 97 +55 63 23 2 560 800 10 0 58 +56 53 12 -31 0 960 10 39 0 +57 32 12 7 0 966 10 0 84 +58 36 26 -2 740 980 10 55 0 +59 21 24 -11 0 972 10 21 0 +60 17 34 3 0 971 10 0 88 +61 12 24 13 0 964 10 0 32 +62 24 58 19 113 353 10 0 27 +63 27 69 -30 0 955 10 49 0 +64 15 77 -5 0 943 10 41 0 +65 62 77 -9 0 940 10 20 0 +66 49 73 -11 0 949 10 83 0 +67 67 5 25 228 468 10 0 85 +68 56 39 -22 0 968 10 93 0 +69 37 47 -12 108 348 10 11 0 +70 37 56 5 0 968 10 0 1 +71 57 68 -16 0 950 10 9 0 +72 47 16 25 0 967 10 0 40 +73 44 17 9 0 969 10 0 100 +74 46 13 -6 622 862 10 25 0 +75 49 11 18 0 962 10 0 91 +76 49 42 -36 212 452 10 48 0 +77 53 43 -27 730 970 10 47 0 +78 61 52 -16 0 958 10 10 0 +79 57 48 -27 307 547 10 31 0 +80 56 37 6 0 968 10 0 26 +81 55 54 -12 0 962 10 18 0 +82 15 47 16 0 966 10 0 24 +83 14 37 11 0 968 10 0 66 +84 11 31 -7 354 594 10 57 0 +85 16 22 -25 0 966 10 67 0 +86 4 18 -8 0 954 10 15 0 +87 28 18 26 314 554 10 0 45 +88 26 52 -3 0 970 10 60 0 +89 26 35 -17 0 981 10 19 0 +90 31 67 -29 0 957 10 23 0 +91 15 19 -18 0 964 10 75 0 +92 22 22 2 18 258 10 0 2 +93 18 24 22 0 969 10 0 68 +94 26 27 27 0 977 10 0 16 +95 25 24 20 0 975 10 0 14 +96 22 27 -10 0 974 10 51 0 +97 25 21 -18 0 972 10 54 0 +98 19 21 -5 0 968 10 7 0 +99 20 26 9 263 503 10 0 44 +100 18 18 -9 725 965 10 73 0 diff --git a/jsprit-instances/instances/lilim/lr209.txt b/jsprit-instances/instances/lilim/lr209.txt new file mode 100644 index 00000000..24616117 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr209.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 10 636 919 10 0 55 +2 35 17 7 74 351 10 0 23 +3 55 45 13 498 613 10 0 54 +4 55 20 19 470 965 10 0 74 +5 15 30 -9 20 370 10 52 0 +6 25 30 3 266 663 0 0 101 +7 20 50 5 292 449 10 0 10 +8 10 43 -19 288 597 10 16 0 +9 55 60 -15 254 643 10 71 0 +10 30 60 -5 496 713 10 7 0 +11 20 65 12 33 510 10 0 63 +12 50 35 19 170 403 10 0 41 +13 30 25 23 426 978 10 0 42 +14 15 10 20 32 454 10 0 18 +15 30 5 -9 30 529 10 73 0 +16 10 20 19 222 423 10 0 8 +17 5 30 2 409 959 10 0 36 +18 20 40 -20 349 462 10 14 0 +19 15 60 -27 215 432 10 31 0 +20 45 65 -9 538 709 10 88 0 +21 45 20 11 156 389 10 0 72 +22 45 10 -31 280 623 10 39 0 +23 55 5 -7 36 513 10 2 0 +24 65 35 -3 633 918 10 90 0 +25 65 20 -23 400 956 10 79 0 +26 45 30 -16 548 707 10 28 0 +27 35 40 16 5 612 10 0 47 +28 41 37 16 44 325 10 0 26 +29 64 42 9 129 374 10 0 40 +30 40 60 21 115 498 10 0 33 +31 31 52 27 91 336 10 0 19 +32 35 69 23 602 835 10 0 48 +33 53 52 -21 24 646 10 30 0 +34 65 55 -6 487 656 10 69 0 +35 63 65 8 439 948 10 0 68 +36 2 60 -2 41 710 10 17 0 +37 20 20 -27 563 736 10 94 0 +38 5 5 16 147 560 10 0 49 +39 60 12 31 33 797 10 0 22 +40 40 25 -9 243 554 10 29 0 +41 42 7 -19 225 682 10 12 0 +42 24 12 -23 25 616 10 13 0 +43 23 3 7 578 747 10 0 91 +44 11 14 -16 72 501 10 82 0 +45 6 38 -35 29 669 10 86 0 +46 2 48 -2 458 685 10 92 0 +47 8 56 -16 34 362 10 27 0 +48 13 52 -23 694 962 10 32 0 +49 6 68 -16 444 597 10 38 0 +50 47 47 -19 499 690 10 62 0 +51 49 58 10 296 505 10 0 81 +52 27 43 9 111 362 10 0 5 +53 37 31 14 301 602 10 0 97 +54 57 29 -13 595 780 10 3 0 +55 63 23 -10 442 917 10 1 0 +56 53 12 -6 426 851 10 80 0 +57 32 12 -18 366 585 10 75 0 +58 36 26 18 458 980 0 0 102 +59 21 24 28 17 441 10 0 95 +60 17 34 -13 651 932 10 61 0 +61 12 24 13 246 421 10 0 60 +62 24 58 19 25 583 10 0 50 +63 27 69 -12 34 348 10 11 0 +64 15 77 9 46 523 10 0 77 +65 62 77 -3 49 608 10 78 0 +66 49 73 25 440 845 10 0 70 +67 67 5 25 132 563 10 0 96 +68 56 39 -8 464 925 10 35 0 +69 37 47 6 12 535 10 0 34 +70 37 56 -25 249 968 10 66 0 +71 57 68 15 218 417 10 0 9 +72 47 16 -11 22 377 10 21 0 +73 44 17 9 263 444 10 0 15 +74 46 13 -19 479 965 10 4 0 +75 49 11 18 182 399 10 0 57 +76 49 42 13 166 497 10 0 87 +77 53 43 -9 430 970 10 64 0 +78 61 52 3 212 671 10 0 65 +79 57 48 23 273 580 10 0 25 +80 56 37 6 452 968 10 0 56 +81 55 54 -10 388 479 10 51 0 +82 15 47 16 99 352 10 0 44 +83 14 37 11 21 328 10 0 99 +84 11 31 7 323 624 10 0 89 +85 16 22 -10 333 504 10 98 0 +86 4 18 35 350 503 10 0 45 +87 28 18 -13 380 487 10 76 0 +88 26 52 9 114 553 10 0 20 +89 26 35 -7 649 981 10 84 0 +90 31 67 3 345 534 10 0 24 +91 15 19 -7 675 930 10 43 0 +92 22 22 2 18 673 10 0 46 +93 18 24 -17 339 969 10 100 0 +94 26 27 27 403 536 10 0 37 +95 25 24 -28 22 301 10 59 0 +96 22 27 -25 565 732 10 67 0 +97 25 21 -14 582 703 10 53 0 +98 19 21 10 122 367 10 0 85 +99 20 26 -11 185 580 10 83 0 +100 18 18 17 297 965 10 0 93 +101 25 30 -3 266 663 10 6 0 +102 36 26 -18 458 980 10 58 0 diff --git a/jsprit-instances/instances/lilim/lr210.txt b/jsprit-instances/instances/lilim/lr210.txt new file mode 100644 index 00000000..414b3bc6 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr210.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 10 190 974 10 0 70 +2 35 17 -41 18 792 10 85 0 +3 55 45 -5 289 822 10 42 0 +4 55 20 19 679 800 10 0 55 +5 15 30 -22 20 906 10 93 0 +6 25 30 -27 355 574 10 47 0 +7 20 50 5 72 669 10 0 96 +8 10 43 -1 393 492 10 46 0 +9 55 60 -8 394 503 10 15 0 +10 30 60 16 517 692 10 0 63 +11 20 65 -21 206 325 10 30 0 +12 50 35 -20 15 725 10 95 0 +13 30 25 -2 694 823 10 92 0 +14 15 10 -1 32 694 10 91 0 +15 30 5 8 176 299 10 0 9 +16 10 20 -16 102 543 10 38 0 +17 5 30 2 673 930 10 0 89 +18 20 40 12 229 582 10 0 21 +19 15 60 -9 95 552 10 52 0 +20 45 65 -10 418 829 10 51 0 +21 45 20 -12 18 727 10 18 0 +22 45 10 -9 349 554 10 99 0 +23 55 5 29 206 325 10 0 78 +24 65 35 -18 435 960 10 54 0 +25 65 20 -8 826 956 10 74 0 +26 45 30 -6 328 927 10 80 0 +27 35 40 16 44 315 10 0 48 +28 41 37 16 6 526 10 0 65 +29 64 42 -23 29 513 10 79 0 +30 40 60 21 199 414 10 0 11 +31 31 52 27 17 744 10 0 61 +32 35 69 -26 482 955 10 81 0 +33 53 52 11 24 299 10 0 58 +34 65 55 -25 265 878 10 66 0 +35 63 65 -18 626 873 10 75 0 +36 2 60 5 41 328 10 0 82 +37 20 20 -3 339 960 10 90 0 +38 5 5 16 298 409 10 0 16 +39 60 12 31 33 344 10 0 100 +40 40 25 -18 300 497 10 44 0 +41 42 7 5 336 571 10 0 77 +42 24 12 5 25 292 10 0 3 +43 23 3 -6 458 867 10 69 0 +44 11 14 18 230 343 10 0 40 +45 6 38 16 29 309 10 0 86 +46 2 48 1 338 805 10 0 8 +47 8 56 27 34 602 10 0 6 +48 13 52 -16 200 962 10 27 0 +49 6 68 -9 441 600 10 88 0 +50 47 47 -11 272 917 10 83 0 +51 49 58 10 176 625 10 0 20 +52 27 43 9 11 748 10 0 19 +53 37 31 14 403 500 10 0 72 +54 57 29 18 475 900 10 0 24 +55 63 23 -19 620 739 10 4 0 +56 53 12 6 525 752 0 0 101 +57 32 12 -15 246 705 10 71 0 +58 36 26 -11 854 980 10 33 0 +59 21 24 28 17 972 10 0 94 +60 17 34 -12 449 971 10 97 0 +61 12 24 -27 126 541 10 31 0 +62 24 58 19 168 297 10 0 84 +63 27 69 -16 34 588 10 10 0 +64 15 77 9 154 393 0 0 102 +65 62 77 -16 49 308 10 28 0 +66 49 73 25 532 753 10 0 34 +67 67 5 -10 291 404 10 98 0 +68 56 39 -13 577 812 10 76 0 +69 37 47 6 165 290 10 0 43 +70 37 56 -10 668 968 10 1 0 +71 57 68 15 98 537 10 0 57 +72 47 16 -14 22 915 10 53 0 +73 44 17 -26 143 564 10 87 0 +74 46 13 8 681 802 10 0 25 +75 49 11 18 27 711 10 0 35 +76 49 42 13 281 382 10 0 68 +77 53 43 -5 821 948 10 41 0 +78 61 52 -29 324 559 10 23 0 +79 57 48 23 377 476 10 0 29 +80 56 37 6 719 968 10 0 26 +81 55 54 26 268 599 10 0 32 +82 15 47 -5 23 761 10 36 0 +83 14 37 11 21 842 10 0 50 +84 11 31 -19 425 522 10 62 0 +85 16 22 41 110 727 10 0 2 +86 4 18 -16 230 623 10 45 0 +87 28 18 26 397 470 10 0 73 +88 26 52 9 219 448 10 0 49 +89 26 35 -2 409 981 10 17 0 +90 31 67 3 225 654 10 0 37 +91 15 19 1 222 964 10 0 14 +92 22 22 2 18 159 10 0 13 +93 18 24 22 691 969 10 0 5 +94 26 27 -28 190 749 10 59 0 +95 25 24 20 14 793 10 0 12 +96 22 27 -5 344 953 10 7 0 +97 25 21 12 462 823 10 0 60 +98 19 21 10 21 748 10 0 67 +99 20 26 9 328 437 10 0 22 +100 18 18 -31 821 965 10 39 0 +101 53 12 -6 525 752 10 56 0 +102 15 77 -9 154 393 10 64 0 diff --git a/jsprit-instances/instances/lilim/lr211.txt b/jsprit-instances/instances/lilim/lr211.txt new file mode 100644 index 00000000..05e72271 --- /dev/null +++ b/jsprit-instances/instances/lilim/lr211.txt @@ -0,0 +1,102 @@ +25 1000 1 +0 35 35 0 0 1000 0 0 0 +1 41 49 -14 451 974 10 34 0 +2 35 17 7 18 534 10 0 39 +3 55 45 -12 378 733 10 18 0 +4 55 20 19 477 965 10 0 68 +5 15 30 -9 20 610 10 8 0 +6 25 30 -5 245 684 10 36 0 +7 20 50 5 172 569 10 0 66 +8 10 43 9 245 640 10 0 5 +9 55 60 16 231 666 10 0 65 +10 30 60 16 430 779 10 0 60 +11 20 65 -6 33 511 10 69 0 +12 50 35 19 50 523 10 0 81 +13 30 25 23 462 978 10 0 26 +14 15 10 -9 32 694 10 52 0 +15 30 5 8 30 519 10 0 20 +16 10 20 19 102 543 10 0 44 +17 5 30 2 444 959 10 0 100 +18 20 40 12 229 582 10 0 3 +19 15 60 17 95 552 10 0 83 +20 45 65 -8 418 829 10 15 0 +21 45 20 11 36 509 10 0 75 +22 45 10 -16 246 657 10 38 0 +23 55 5 29 36 514 10 0 90 +24 65 35 -6 435 960 10 25 0 +25 65 20 6 438 956 10 0 24 +26 45 30 -23 428 827 10 13 0 +27 35 40 16 5 548 10 0 32 +28 41 37 16 6 526 10 0 61 +29 64 42 -13 29 513 10 76 0 +30 40 60 -10 91 522 10 51 0 +31 31 52 27 17 501 10 0 62 +32 35 69 -16 482 955 10 27 0 +33 53 52 -25 24 575 10 67 0 +34 65 55 14 367 776 10 0 1 +35 63 65 -7 453 948 10 43 0 +36 2 60 5 41 615 10 0 6 +37 20 20 8 443 856 10 0 58 +38 5 5 16 130 577 10 0 22 +39 60 12 -7 33 655 10 2 0 +40 40 25 -10 201 596 10 98 0 +41 42 7 -9 219 688 10 99 0 +42 24 12 5 25 560 10 0 73 +43 23 3 7 458 867 10 0 35 +44 11 14 -19 59 514 10 16 0 +45 6 38 16 29 589 10 0 84 +46 2 48 -27 338 805 10 47 0 +47 8 56 27 34 602 10 0 46 +48 13 52 36 454 962 10 0 97 +49 6 68 -9 362 679 10 64 0 +50 47 47 13 379 810 10 0 70 +51 49 58 10 176 625 10 0 30 +52 27 43 9 11 502 10 0 14 +53 37 31 -35 256 647 10 86 0 +54 57 29 -2 475 900 10 55 0 +55 63 23 2 441 918 10 0 54 +56 53 12 -8 412 865 10 74 0 +57 32 12 -9 246 705 10 88 0 +58 36 26 -8 479 980 10 37 0 +59 21 24 -27 17 681 10 94 0 +60 17 34 -16 449 971 10 10 0 +61 12 24 -16 126 541 10 28 0 +62 24 58 -27 25 544 10 31 0 +63 27 69 10 34 588 10 0 96 +64 15 77 9 46 524 10 0 49 +65 62 77 -16 49 568 10 9 0 +66 49 73 -5 421 864 10 7 0 +67 67 5 25 120 575 10 0 33 +68 56 39 -19 459 930 10 4 0 +69 37 47 6 12 513 10 0 11 +70 37 56 -13 368 968 10 50 0 +71 57 68 -25 98 537 10 72 0 +72 47 16 25 22 617 10 0 71 +73 44 17 -5 143 564 10 42 0 +74 46 13 8 482 965 10 0 56 +75 49 11 -11 62 519 10 21 0 +76 49 42 13 129 534 10 0 29 +77 53 43 -6 460 970 10 80 0 +78 61 52 3 207 676 10 0 93 +79 57 48 -20 230 623 10 95 0 +80 56 37 6 470 968 10 0 77 +81 55 54 -19 268 599 10 12 0 +82 15 47 16 23 515 10 0 92 +83 14 37 -17 21 568 10 19 0 +84 11 31 -16 278 669 10 45 0 +85 16 22 41 213 624 10 0 87 +86 4 18 35 230 623 10 0 53 +87 28 18 -41 287 580 10 85 0 +88 26 52 9 104 563 10 0 57 +89 26 35 -1 409 981 10 91 0 +90 31 67 -29 225 654 10 23 0 +91 15 19 1 469 964 10 0 89 +92 22 22 -16 18 585 10 82 0 +93 18 24 -3 414 969 10 78 0 +94 26 27 27 283 656 10 0 59 +95 25 24 20 14 533 10 0 79 +96 22 27 -10 445 852 10 63 0 +97 25 21 -36 462 823 10 48 0 +98 19 21 10 21 506 10 0 40 +99 20 26 9 164 601 10 0 41 +100 18 18 -2 391 965 10 17 0 diff --git a/jsprit-instances/instances/lilim/lrc101.txt b/jsprit-instances/instances/lilim/lrc101.txt new file mode 100644 index 00000000..b2ecc4aa --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc101.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 145 175 0 0 105 +2 22 75 -10 50 80 10 45 0 +3 22 85 -10 109 139 10 8 0 +4 20 80 -20 141 171 10 5 0 +5 20 85 20 41 71 10 0 4 +6 18 75 -20 95 125 10 7 0 +7 15 75 20 79 109 10 0 6 +8 15 80 10 91 121 10 0 3 +9 10 35 20 91 121 10 0 13 +10 10 40 30 119 149 10 0 17 +11 8 40 40 59 89 10 0 15 +12 8 45 20 64 94 10 0 46 +13 5 35 -20 142 172 10 9 0 +14 5 45 10 35 65 10 0 47 +15 2 40 -40 58 88 10 11 0 +16 0 40 -9 72 102 10 82 0 +17 0 45 -30 149 179 10 10 0 +18 44 5 -40 87 117 10 19 0 +19 42 10 40 72 102 10 0 18 +20 42 15 -10 122 152 10 49 0 +21 40 5 -30 67 97 10 23 0 +22 40 15 40 92 122 10 0 24 +23 38 5 30 65 95 10 0 21 +24 38 15 -40 148 178 10 22 0 +25 35 5 20 154 184 0 0 101 +26 95 30 -10 115 145 10 28 0 +27 95 35 20 62 92 10 0 91 +28 92 30 10 62 92 10 0 26 +29 90 35 10 67 97 10 0 93 +30 88 30 10 74 104 10 0 32 +31 88 35 20 61 91 10 0 89 +32 87 30 -10 131 161 10 30 0 +33 85 25 10 51 81 10 0 34 +34 85 35 -10 111 141 10 33 0 +35 67 85 -30 139 169 10 40 0 +36 65 85 -8 43 73 10 72 0 +37 65 82 -20 124 154 10 41 0 +38 62 80 30 75 105 10 0 43 +39 60 80 10 37 67 10 0 54 +40 60 85 30 85 115 10 0 35 +41 58 75 20 92 122 10 0 37 +42 55 80 10 33 63 10 0 44 +43 55 85 -30 128 158 10 38 0 +44 55 82 -10 64 94 10 42 0 +45 20 82 10 37 67 10 0 2 +46 18 80 -20 113 143 10 12 0 +47 2 45 -10 45 75 10 14 0 +48 42 5 -14 151 181 10 83 0 +49 42 12 10 104 134 10 0 20 +50 72 35 30 116 146 10 0 80 +51 55 20 -6 83 113 10 63 0 +52 25 30 3 52 82 10 0 57 +53 20 50 5 91 121 10 0 100 +54 55 60 -10 139 169 10 39 0 +55 30 60 -30 140 170 10 79 0 +56 50 35 -6 130 160 10 90 0 +57 30 25 -3 96 126 10 52 0 +58 15 10 -16 152 182 10 75 0 +59 10 20 19 42 72 10 0 97 +60 15 60 17 155 185 10 0 70 +61 45 65 9 66 96 10 0 68 +62 65 35 3 52 82 10 0 94 +63 65 20 6 39 69 10 0 51 +64 45 30 17 53 83 0 0 103 +65 35 40 16 11 41 10 0 74 +66 41 37 -18 133 163 10 84 0 +67 64 42 9 70 100 10 0 71 +68 40 60 -9 144 174 10 61 0 +69 31 52 27 41 71 10 0 78 +70 35 69 -17 180 210 10 60 0 +71 65 55 -9 65 95 10 67 0 +72 63 65 8 30 60 10 0 36 +73 2 60 5 77 107 0 0 106 +74 20 20 -16 141 171 10 65 0 +75 5 5 16 74 104 10 0 58 +76 60 12 31 75 105 0 0 104 +77 23 3 -13 150 180 10 87 0 +78 8 56 -27 90 120 10 69 0 +79 6 68 30 89 119 10 0 55 +80 47 47 -30 192 222 10 50 0 +81 49 58 10 86 116 10 0 96 +82 27 43 9 42 72 10 0 16 +83 37 31 14 35 65 10 0 48 +84 57 29 18 96 126 10 0 66 +85 63 23 2 87 117 0 0 102 +86 21 24 -15 87 117 10 99 0 +87 12 24 13 90 120 10 0 77 +88 24 58 -9 67 97 10 98 0 +89 67 5 -20 144 174 10 31 0 +90 37 47 6 86 116 10 0 56 +91 49 42 -20 167 197 10 27 0 +92 53 43 14 14 44 10 0 95 +93 61 52 -10 178 208 10 29 0 +94 57 48 -3 95 125 10 62 0 +95 56 37 -14 34 64 10 92 0 +96 55 54 -10 132 162 10 81 0 +97 4 18 -19 120 150 10 59 0 +98 26 52 9 46 76 10 0 88 +99 26 35 15 77 107 10 0 86 +100 31 67 -5 180 210 10 53 0 +101 35 5 -20 154 184 10 25 0 +102 63 23 -2 87 117 10 85 0 +103 45 30 -17 53 83 10 64 0 +104 60 12 -31 75 105 10 76 0 +105 25 85 -20 145 175 10 1 0 +106 2 60 -5 77 107 10 73 0 diff --git a/jsprit-instances/instances/lilim/lrc102.txt b/jsprit-instances/instances/lilim/lrc102.txt new file mode 100644 index 00000000..0b320ce5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc102.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 -10 0 191 10 45 0 +2 22 75 30 0 199 10 0 3 +3 22 85 -30 0 190 10 2 0 +4 20 80 -10 141 171 10 46 0 +5 20 85 20 0 189 10 0 60 +6 18 75 20 95 125 10 0 98 +7 15 75 -30 0 194 10 79 0 +8 15 80 10 91 121 0 0 101 +9 10 35 -20 91 121 10 16 0 +10 10 40 -27 119 149 10 78 0 +11 8 40 40 59 89 10 0 73 +12 8 45 -10 0 197 10 13 0 +13 5 35 10 142 172 10 0 12 +14 5 45 10 35 65 10 0 15 +15 2 40 -10 58 88 10 14 0 +16 0 40 20 72 102 10 0 9 +17 0 45 -19 149 179 10 88 0 +18 44 5 -14 87 117 10 83 0 +19 42 10 40 72 102 10 0 23 +20 42 15 -40 122 152 10 22 0 +21 40 5 10 0 185 10 0 25 +22 40 15 40 92 122 10 0 20 +23 38 5 -40 65 95 10 19 0 +24 38 15 -10 148 178 10 49 0 +25 35 5 -10 154 184 10 21 0 +26 95 30 30 0 171 10 0 50 +27 95 35 -10 62 92 10 33 0 +28 92 30 10 62 92 10 0 31 +29 90 35 10 67 97 10 0 89 +30 88 30 -3 74 104 10 62 0 +31 88 35 -10 0 179 10 28 0 +32 87 30 10 131 161 0 0 103 +33 85 25 10 51 81 10 0 27 +34 85 35 30 0 182 10 0 93 +35 67 85 -30 139 169 10 40 0 +36 65 85 40 43 73 10 0 44 +37 65 82 -30 0 189 10 38 0 +38 62 80 30 75 105 10 0 37 +39 60 80 10 37 67 10 0 84 +40 60 85 30 85 115 10 0 35 +41 58 75 20 92 122 10 0 43 +42 55 80 10 33 63 10 0 68 +43 55 85 -20 128 158 10 41 0 +44 55 82 -40 64 94 10 36 0 +45 20 82 10 37 67 10 0 1 +46 18 80 10 113 143 10 0 4 +47 2 45 10 45 75 10 0 97 +48 42 5 -16 0 184 10 65 0 +49 42 12 10 104 134 10 0 24 +50 72 35 -30 0 194 10 26 0 +51 55 20 -31 83 113 10 76 0 +52 25 30 -19 0 205 10 59 0 +53 20 50 -27 91 121 10 69 0 +54 55 60 -10 139 169 10 81 0 +55 30 60 -9 140 170 10 82 0 +56 50 35 19 130 160 10 0 66 +57 30 25 -13 96 126 10 91 0 +58 15 10 -13 152 182 10 87 0 +59 10 20 19 0 187 10 0 52 +60 15 60 -20 155 185 10 5 0 +61 45 65 9 66 96 10 0 90 +62 65 35 3 52 82 10 0 30 +63 65 20 -2 39 69 10 85 0 +64 45 30 17 53 83 10 0 86 +65 35 40 16 11 41 10 0 48 +66 41 37 -19 133 163 10 56 0 +67 64 42 -14 70 100 10 71 0 +68 40 60 -10 144 174 10 42 0 +69 31 52 27 41 71 10 0 53 +70 35 69 -3 180 210 10 100 0 +71 65 55 14 65 95 10 0 67 +72 63 65 8 0 202 0 0 104 +73 2 60 -40 77 107 10 11 0 +74 20 20 -15 141 171 10 99 0 +75 5 5 16 0 172 0 0 102 +76 60 12 31 75 105 10 0 51 +77 23 3 7 150 180 0 0 105 +78 8 56 27 90 120 10 0 10 +79 6 68 30 89 119 10 0 7 +80 47 47 -23 192 222 10 94 0 +81 49 58 10 86 116 10 0 54 +82 27 43 9 0 215 10 0 55 +83 37 31 14 0 210 10 0 18 +84 57 29 -10 96 126 10 39 0 +85 63 23 2 0 194 10 0 63 +86 21 24 -17 87 117 10 64 0 +87 12 24 13 90 120 10 0 58 +88 24 58 19 67 97 10 0 17 +89 67 5 -10 144 174 10 29 0 +90 37 47 -9 86 116 10 61 0 +91 49 42 13 0 217 10 0 57 +92 53 43 14 14 44 10 0 95 +93 61 52 -30 178 208 10 34 0 +94 57 48 23 0 212 10 0 80 +95 56 37 -14 0 209 10 92 0 +96 55 54 26 0 214 0 0 106 +97 4 18 -10 120 150 10 47 0 +98 26 52 -20 0 215 10 6 0 +99 26 35 15 77 107 10 0 74 +100 31 67 3 180 210 10 0 70 +101 15 80 -10 91 121 10 8 0 +102 5 5 -16 0 172 10 75 0 +103 87 30 -10 131 161 10 32 0 +104 63 65 -8 0 202 10 72 0 +105 23 3 -7 150 180 10 77 0 +106 55 54 -26 0 214 10 96 0 diff --git a/jsprit-instances/instances/lilim/lrc103.txt b/jsprit-instances/instances/lilim/lrc103.txt new file mode 100644 index 00000000..cae795af --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc103.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 0 191 10 0 3 +2 22 75 30 0 199 10 0 5 +3 22 85 -20 0 190 10 1 0 +4 20 80 -27 141 171 10 78 0 +5 20 85 -30 0 189 10 2 0 +6 18 75 20 95 125 10 0 55 +7 15 75 20 0 194 10 0 46 +8 15 80 -10 91 121 10 45 0 +9 10 35 20 91 121 10 0 87 +10 10 40 30 119 149 10 0 13 +11 8 40 -10 59 89 10 14 0 +12 8 45 20 0 197 10 0 17 +13 5 35 -30 142 172 10 10 0 +14 5 45 10 0 194 10 0 11 +15 2 40 -9 58 88 10 82 0 +16 0 40 -5 0 188 10 53 0 +17 0 45 -20 149 179 10 12 0 +18 44 5 20 0 184 10 0 23 +19 42 10 -40 0 189 10 22 0 +20 42 15 10 0 194 10 0 48 +21 40 5 10 0 185 10 0 49 +22 40 15 40 92 122 10 0 19 +23 38 5 -20 65 95 10 18 0 +24 38 15 -20 0 194 10 25 0 +25 35 5 20 154 184 10 0 24 +26 95 30 -10 0 171 10 32 0 +27 95 35 20 62 92 10 0 30 +28 92 30 10 0 174 0 0 102 +29 90 35 10 0 177 10 0 34 +30 88 30 -20 74 104 10 27 0 +31 88 35 -10 0 179 10 33 0 +32 87 30 10 0 178 10 0 26 +33 85 25 10 51 81 10 0 31 +34 85 35 -10 0 182 10 29 0 +35 67 85 -10 139 169 10 39 0 +36 65 85 40 43 73 10 0 37 +37 65 82 -40 0 189 10 36 0 +38 62 80 -10 75 105 10 44 0 +39 60 80 10 37 67 10 0 35 +40 60 85 30 85 115 10 0 93 +41 58 75 20 92 122 10 0 72 +42 55 80 -9 33 63 10 61 0 +43 55 85 20 0 191 10 0 80 +44 55 82 10 64 94 10 0 38 +45 20 82 10 37 67 10 0 8 +46 18 80 -20 0 192 10 7 0 +47 2 45 10 0 191 0 0 104 +48 42 5 -10 0 184 10 20 0 +49 42 12 -10 104 134 10 21 0 +50 72 35 30 0 194 10 0 67 +51 55 20 19 0 196 10 0 63 +52 25 30 -8 0 205 10 74 0 +53 20 50 5 91 121 10 0 16 +54 55 60 16 0 211 0 0 103 +55 30 60 -20 140 170 10 6 0 +56 50 35 19 130 160 10 0 66 +57 30 25 23 0 203 0 0 101 +58 15 10 -35 152 182 10 97 0 +59 10 20 19 0 187 10 0 86 +60 15 60 -9 0 203 10 98 0 +61 45 65 9 0 214 10 0 42 +62 65 35 -14 52 82 10 92 0 +63 65 20 -19 0 190 10 51 0 +64 45 30 -16 53 83 10 65 0 +65 35 40 16 11 41 10 0 64 +66 41 37 -19 133 163 10 56 0 +67 64 42 -30 70 100 10 50 0 +68 40 60 21 144 174 0 0 105 +69 31 52 27 41 71 10 0 88 +70 35 69 -3 180 210 10 100 0 +71 65 55 14 0 204 10 0 94 +72 63 65 -20 0 202 10 41 0 +73 2 60 5 0 190 10 0 79 +74 20 20 8 141 171 10 0 52 +75 5 5 16 0 172 10 0 77 +76 60 12 31 75 105 10 0 85 +77 23 3 -16 150 180 10 75 0 +78 8 56 27 90 120 10 0 4 +79 6 68 -5 89 119 10 73 0 +80 47 47 -20 192 222 10 43 0 +81 49 58 10 0 217 10 0 96 +82 27 43 9 0 215 10 0 15 +83 37 31 14 0 210 10 0 89 +84 57 29 18 96 126 0 0 106 +85 63 23 -31 0 194 10 76 0 +86 21 24 -19 0 197 10 59 0 +87 12 24 -20 90 120 10 9 0 +88 24 58 -27 67 97 10 69 0 +89 67 5 -14 0 177 10 83 0 +90 37 47 6 0 225 10 0 99 +91 49 42 -6 0 217 10 95 0 +92 53 43 14 14 44 10 0 62 +93 61 52 -30 178 208 10 40 0 +94 57 48 -14 0 212 10 71 0 +95 56 37 6 0 209 10 0 91 +96 55 54 -10 0 214 10 81 0 +97 4 18 35 0 181 10 0 58 +98 26 52 9 0 215 10 0 60 +99 26 35 -6 77 107 10 90 0 +100 31 67 3 180 210 10 0 70 +101 30 25 -23 0 203 10 57 0 +102 92 30 -10 0 174 10 28 0 +103 55 60 -16 0 211 10 54 0 +104 2 45 -10 0 191 10 47 0 +105 40 60 -21 144 174 10 68 0 +106 57 29 -18 96 126 10 84 0 diff --git a/jsprit-instances/instances/lilim/lrc104.txt b/jsprit-instances/instances/lilim/lrc104.txt new file mode 100644 index 00000000..a2827fea --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc104.txt @@ -0,0 +1,110 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 -23 0 191 10 70 0 +2 22 75 -20 0 199 10 7 0 +3 22 85 -9 0 190 10 61 0 +4 20 80 -10 141 171 10 46 0 +5 20 85 20 0 189 10 0 100 +6 18 75 -5 0 196 10 73 0 +7 15 75 20 0 194 10 0 2 +8 15 80 10 91 121 10 0 68 +9 10 35 20 91 121 10 0 86 +10 10 40 -20 0 198 10 16 0 +11 8 40 -10 59 89 10 47 0 +12 8 45 20 0 197 10 0 82 +13 5 35 10 142 172 0 0 108 +14 5 45 10 0 194 10 0 15 +15 2 40 -10 58 88 10 14 0 +16 0 40 20 0 188 10 0 10 +17 0 45 -9 0 189 10 98 0 +18 44 5 -10 0 184 10 21 0 +19 42 10 40 0 189 10 0 48 +20 42 15 10 0 194 10 0 22 +21 40 5 10 0 185 10 0 18 +22 40 15 -10 0 195 10 20 0 +23 38 5 -10 65 95 10 49 0 +24 38 15 -20 0 194 10 25 0 +25 35 5 20 154 184 10 0 24 +26 95 30 30 0 171 10 0 31 +27 95 35 20 0 172 10 0 29 +28 92 30 -10 0 174 10 33 0 +29 90 35 -20 0 177 10 27 0 +30 88 30 10 0 178 10 0 34 +31 88 35 -30 0 179 10 26 0 +32 87 30 10 0 178 0 0 107 +33 85 25 10 0 178 10 0 28 +34 85 35 -10 0 182 10 30 0 +35 67 85 20 0 185 10 0 41 +36 65 85 -20 0 186 10 43 0 +37 65 82 -10 0 189 10 42 0 +38 62 80 -10 75 105 10 44 0 +39 60 80 -30 0 193 10 40 0 +40 60 85 30 0 189 10 0 39 +41 58 75 -20 0 199 10 35 0 +42 55 80 10 0 196 10 0 37 +43 55 85 20 0 191 10 0 36 +44 55 82 10 64 94 10 0 38 +45 20 82 10 0 192 0 0 101 +46 18 80 10 0 192 10 0 4 +47 2 45 10 0 191 10 0 11 +48 42 5 -40 0 184 10 19 0 +49 42 12 10 0 191 10 0 23 +50 72 35 -14 0 194 10 92 0 +51 55 20 -18 0 196 10 84 0 +52 25 30 -23 0 205 10 57 0 +53 20 50 -27 91 121 10 69 0 +54 55 60 -8 0 211 10 72 0 +55 30 60 16 140 170 0 0 104 +56 50 35 -13 0 211 10 80 0 +57 30 25 23 0 203 10 0 52 +58 15 10 20 152 182 0 0 103 +59 10 20 -13 0 187 10 87 0 +60 15 60 -19 0 203 10 88 0 +61 45 65 9 0 214 10 0 3 +62 65 35 3 52 82 10 0 71 +63 65 20 6 0 190 10 0 64 +64 45 30 -6 0 209 10 63 0 +65 35 40 -6 0 218 10 90 0 +66 41 37 16 0 216 0 0 106 +67 64 42 9 70 100 10 0 81 +68 40 60 -10 0 220 10 8 0 +69 31 52 27 41 71 10 0 53 +70 35 69 23 0 210 10 0 1 +71 65 55 -3 0 204 10 62 0 +72 63 65 8 0 202 10 0 54 +73 2 60 5 0 190 10 0 6 +74 20 20 8 141 171 0 0 102 +75 5 5 -15 0 172 10 99 0 +76 60 12 31 75 105 10 0 83 +77 23 3 -35 150 180 10 97 0 +78 8 56 27 0 197 10 0 79 +79 6 68 -27 89 119 10 78 0 +80 47 47 13 0 222 10 0 56 +81 49 58 -9 0 217 10 67 0 +82 27 43 -20 0 215 10 12 0 +83 37 31 -31 0 210 10 76 0 +84 57 29 18 96 126 10 0 51 +85 63 23 2 0 194 10 0 89 +86 21 24 -20 0 197 10 9 0 +87 12 24 13 90 120 10 0 59 +88 24 58 19 0 212 10 0 60 +89 67 5 -2 0 177 10 85 0 +90 37 47 6 0 225 10 0 65 +91 49 42 13 0 217 10 0 93 +92 53 43 14 14 44 10 0 50 +93 61 52 -13 0 208 10 91 0 +94 57 48 23 0 212 0 0 105 +95 56 37 6 0 209 10 0 96 +96 55 54 -6 0 214 10 95 0 +97 4 18 35 0 181 10 0 77 +98 26 52 9 0 215 10 0 17 +99 26 35 15 77 107 10 0 75 +100 31 67 -20 180 210 10 5 0 +101 20 82 -10 0 192 10 45 0 +102 20 20 -8 141 171 10 74 0 +103 15 10 -20 152 182 10 58 0 +104 30 60 -16 140 170 10 55 0 +105 57 48 -23 0 212 10 94 0 +106 41 37 -16 0 216 10 66 0 +107 87 30 -10 0 178 10 32 0 +108 5 35 -10 142 172 10 13 0 diff --git a/jsprit-instances/instances/lilim/lrc105.txt b/jsprit-instances/instances/lilim/lrc105.txt new file mode 100644 index 00000000..97a21f25 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc105.txt @@ -0,0 +1,110 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 71 191 10 0 100 +2 22 75 30 30 150 10 0 5 +3 22 85 -20 64 184 10 6 0 +4 20 80 40 151 161 0 0 107 +5 20 85 -30 40 160 10 2 0 +6 18 75 20 96 123 10 0 3 +7 15 75 20 35 155 10 0 68 +8 15 80 10 101 111 10 0 46 +9 10 35 -40 101 111 10 11 0 +10 10 40 30 123 144 10 0 17 +11 8 40 40 69 79 10 0 9 +12 8 45 -9 32 152 10 82 0 +13 5 35 -10 152 162 10 14 0 +14 5 45 10 35 117 10 0 13 +15 2 40 20 68 78 10 0 97 +16 0 40 20 59 114 0 0 103 +17 0 45 -30 147 180 10 10 0 +18 44 5 20 79 124 10 0 25 +19 42 10 40 58 115 10 0 20 +20 42 15 -40 111 162 10 19 0 +21 40 5 -10 45 165 10 48 0 +22 40 15 -16 94 119 10 65 0 +23 38 5 -14 75 85 10 83 0 +24 38 15 10 128 194 0 0 105 +25 35 5 -20 171 181 10 18 0 +26 95 30 30 58 171 10 0 30 +27 95 35 20 60 93 10 0 50 +28 92 30 -10 55 120 10 29 0 +29 90 35 10 52 112 10 0 28 +30 88 30 -30 75 102 10 26 0 +31 88 35 20 50 170 10 0 34 +32 87 30 10 116 175 10 0 80 +33 85 25 10 51 85 10 0 76 +34 85 35 -20 62 182 10 31 0 +35 67 85 20 138 169 0 0 104 +36 65 85 40 43 78 10 0 37 +37 65 82 -40 69 189 10 36 0 +38 62 80 30 85 95 10 0 43 +39 60 80 10 36 74 10 0 40 +40 60 85 -10 87 112 10 39 0 +41 58 75 20 92 121 10 0 96 +42 55 80 10 33 66 10 0 61 +43 55 85 -30 117 168 10 38 0 +44 55 82 10 74 84 10 0 70 +45 20 82 10 37 72 10 0 79 +46 18 80 -10 98 157 10 8 0 +47 2 45 -9 38 109 10 98 0 +48 42 5 10 64 184 10 0 21 +49 42 12 10 109 128 10 0 77 +50 72 35 -20 71 191 10 27 0 +51 55 20 -6 69 126 10 63 0 +52 25 30 -17 25 145 10 64 0 +53 20 50 -6 101 111 10 90 0 +54 55 60 16 127 180 10 0 93 +55 30 60 16 150 160 0 0 101 +56 50 35 -16 130 159 10 66 0 +57 30 25 -6 82 139 10 95 0 +58 15 10 -19 172 182 10 59 0 +59 10 20 19 42 162 10 0 58 +60 15 60 -5 137 202 10 73 0 +61 45 65 -10 55 106 10 42 0 +62 65 35 3 62 72 10 0 84 +63 65 20 6 39 108 10 0 51 +64 45 30 17 53 82 10 0 52 +65 35 40 16 11 43 10 0 22 +66 41 37 16 134 161 10 0 56 +67 64 42 9 80 90 10 0 85 +68 40 60 -20 144 173 10 7 0 +69 31 52 27 51 61 10 0 88 +70 35 69 -10 172 210 10 44 0 +71 65 55 14 52 107 10 0 81 +72 63 65 8 27 147 10 0 94 +73 2 60 5 65 118 10 0 60 +74 20 20 -15 151 161 10 99 0 +75 5 5 -13 57 172 10 87 0 +76 60 12 -10 85 95 10 33 0 +77 23 3 -10 163 173 10 49 0 +78 8 56 27 90 119 0 0 108 +79 6 68 -10 99 109 10 45 0 +80 47 47 -10 190 222 10 32 0 +81 49 58 -14 80 121 10 71 0 +82 27 43 9 14 134 10 0 12 +83 37 31 14 19 139 10 0 23 +84 57 29 -3 106 116 10 62 0 +85 63 23 -9 42 162 10 67 0 +86 21 24 -14 77 126 10 92 0 +87 12 24 13 100 110 10 0 75 +88 24 58 -27 67 96 10 69 0 +89 67 5 25 105 177 0 0 102 +90 37 47 6 74 127 10 0 53 +91 49 42 13 97 217 0 0 106 +92 53 43 14 15 25 10 0 86 +93 61 52 -16 173 208 10 54 0 +94 57 48 -8 50 170 10 72 0 +95 56 37 6 20 140 10 0 57 +96 55 54 -20 87 207 10 41 0 +97 4 18 -20 112 157 10 15 0 +98 26 52 9 14 134 10 0 47 +99 26 35 15 87 97 10 0 74 +100 31 67 -20 200 210 10 1 0 +101 30 60 -16 150 160 10 55 0 +102 67 5 -25 105 177 10 89 0 +103 0 40 -20 59 114 10 16 0 +104 67 85 -20 138 169 10 35 0 +105 38 15 -10 128 194 10 24 0 +106 49 42 -13 97 217 10 91 0 +107 20 80 -40 151 161 10 4 0 +108 8 56 -27 90 119 10 78 0 diff --git a/jsprit-instances/instances/lilim/lrc106.txt b/jsprit-instances/instances/lilim/lrc106.txt new file mode 100644 index 00000000..65c38443 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc106.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 130 190 0 0 104 +2 22 75 30 35 95 10 0 5 +3 22 85 -10 94 154 10 46 0 +4 20 80 -10 126 186 10 45 0 +5 20 85 -30 40 100 10 2 0 +6 18 75 20 80 140 10 0 100 +7 15 75 -10 64 124 10 8 0 +8 15 80 10 76 136 10 0 7 +9 10 35 20 76 136 10 0 17 +10 10 40 -5 104 164 10 53 0 +11 8 40 40 44 104 10 0 58 +12 8 45 20 49 109 0 0 103 +13 5 35 -27 127 187 10 69 0 +14 5 45 10 35 95 10 0 74 +15 2 40 20 43 103 10 0 16 +16 0 40 -20 57 117 10 15 0 +17 0 45 -20 129 189 10 9 0 +18 44 5 20 72 132 10 0 48 +19 42 10 -17 57 117 10 64 0 +20 42 15 -28 107 167 10 86 0 +21 40 5 -14 52 112 10 83 0 +22 40 15 -23 77 137 10 57 0 +23 38 5 -16 50 110 10 65 0 +24 38 15 10 133 193 10 0 91 +25 35 5 20 124 184 10 0 77 +26 95 30 30 100 160 0 0 101 +27 95 35 20 57 117 10 0 28 +28 92 30 -20 55 115 10 27 0 +29 90 35 -20 52 112 10 31 0 +30 88 30 10 59 119 10 0 93 +31 88 35 20 50 110 10 0 29 +32 87 30 -9 116 176 10 67 0 +33 85 25 10 51 111 10 0 89 +34 85 35 30 96 156 10 0 50 +35 67 85 -10 124 184 10 37 0 +36 65 85 40 43 103 10 0 43 +37 65 82 10 109 169 10 0 35 +38 62 80 -10 60 120 10 44 0 +39 60 80 -10 36 96 10 42 0 +40 60 85 30 70 130 10 0 41 +41 58 75 -30 77 137 10 40 0 +42 55 80 10 33 93 10 0 39 +43 55 85 -40 113 173 10 36 0 +44 55 82 10 49 109 10 0 38 +45 20 82 10 37 97 10 0 4 +46 18 80 10 98 158 10 0 3 +47 2 45 10 38 98 10 0 78 +48 42 5 -20 124 184 10 18 0 +49 42 12 -15 89 149 10 99 0 +50 72 35 -30 101 161 10 34 0 +51 55 20 19 68 128 0 0 102 +52 25 30 -9 37 97 10 82 0 +53 20 50 5 76 136 10 0 10 +54 55 60 16 124 184 10 0 68 +55 30 60 16 125 185 0 0 106 +56 50 35 -31 115 175 10 76 0 +57 30 25 23 81 141 10 0 22 +58 15 10 -40 122 182 10 11 0 +59 10 20 19 42 102 10 0 97 +60 15 60 17 140 200 10 0 70 +61 45 65 9 51 111 10 0 81 +62 65 35 -6 37 97 10 95 0 +63 65 20 6 39 99 10 0 66 +64 45 30 17 38 98 10 0 19 +65 35 40 16 11 71 10 0 23 +66 41 37 -6 118 178 10 63 0 +67 64 42 9 55 115 10 0 32 +68 40 60 -16 129 189 10 54 0 +69 31 52 27 26 86 10 0 13 +70 35 69 -17 150 210 10 60 0 +71 65 55 -8 50 110 10 72 0 +72 63 65 8 27 87 10 0 71 +73 2 60 5 62 122 10 0 79 +74 20 20 -10 126 186 10 14 0 +75 5 5 -13 59 119 10 87 0 +76 60 12 31 60 120 10 0 56 +77 23 3 -20 120 180 10 25 0 +78 8 56 -10 75 135 10 47 0 +79 6 68 -5 74 134 10 73 0 +80 47 47 13 162 222 0 0 105 +81 49 58 -9 71 131 10 61 0 +82 27 43 9 27 87 10 0 52 +83 37 31 14 20 80 10 0 21 +84 57 29 -2 81 141 10 85 0 +85 63 23 2 72 132 10 0 84 +86 21 24 28 72 132 10 0 20 +87 12 24 13 75 135 10 0 75 +88 24 58 -9 52 112 10 98 0 +89 67 5 -10 117 177 10 33 0 +90 37 47 6 71 131 10 0 94 +91 49 42 -10 152 212 10 24 0 +92 53 43 14 14 74 10 0 96 +93 61 52 -10 148 208 10 30 0 +94 57 48 -6 80 140 10 90 0 +95 56 37 6 20 80 10 0 62 +96 55 54 -14 117 177 10 92 0 +97 4 18 -19 105 165 10 59 0 +98 26 52 9 31 91 10 0 88 +99 26 35 15 62 122 10 0 49 +100 31 67 -20 150 210 10 6 0 +101 95 30 -30 100 160 10 26 0 +102 55 20 -19 68 128 10 51 0 +103 8 45 -20 49 109 10 12 0 +104 25 85 -20 130 190 10 1 0 +105 47 47 -13 162 222 10 80 0 +106 30 60 -16 125 185 10 55 0 diff --git a/jsprit-instances/instances/lilim/lrc107.txt b/jsprit-instances/instances/lilim/lrc107.txt new file mode 100644 index 00000000..d48a83b0 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc107.txt @@ -0,0 +1,108 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 125 191 10 0 46 +2 22 75 30 32 97 10 0 6 +3 22 85 -10 101 146 10 8 0 +4 20 80 40 71 193 10 0 100 +5 20 85 20 40 113 10 0 45 +6 18 75 -30 55 164 10 2 0 +7 15 75 20 69 118 0 0 103 +8 15 80 10 56 155 10 0 3 +9 10 35 -10 51 160 10 47 0 +10 10 40 -20 90 177 10 17 0 +11 8 40 40 33 152 10 0 15 +12 8 45 20 49 108 10 0 13 +13 5 35 -20 62 191 10 12 0 +14 5 45 10 35 117 10 0 16 +15 2 40 -40 39 161 10 11 0 +16 0 40 -10 59 114 10 14 0 +17 0 45 20 60 189 10 0 10 +18 44 5 20 79 124 10 0 48 +19 42 10 40 58 115 10 0 20 +20 42 15 -40 111 162 10 19 0 +21 40 5 10 52 111 10 0 56 +22 40 15 40 55 158 10 0 66 +23 38 5 30 45 164 10 0 49 +24 38 15 -3 128 194 10 52 0 +25 35 5 -17 54 184 10 64 0 +26 95 30 30 105 154 10 0 30 +27 95 35 20 57 172 10 0 32 +28 92 30 10 55 120 10 0 34 +29 90 35 -20 52 112 10 31 0 +30 88 30 -30 52 159 10 26 0 +31 88 35 20 50 110 10 0 29 +32 87 30 -20 116 175 10 27 0 +33 85 25 10 51 178 0 0 101 +34 85 35 -10 100 151 10 28 0 +35 67 85 20 61 185 10 0 36 +36 65 85 -20 43 186 10 35 0 +37 65 82 -10 113 164 10 39 0 +38 62 80 30 37 148 10 0 44 +39 60 80 10 36 191 10 0 37 +40 60 85 -10 50 149 10 42 0 +41 58 75 20 48 165 10 0 43 +42 55 80 10 33 166 10 0 40 +43 55 85 -20 117 168 10 41 0 +44 55 82 -30 35 148 10 38 0 +45 20 82 -20 37 177 10 5 0 +46 18 80 -20 98 157 10 1 0 +47 2 45 10 38 109 10 0 9 +48 42 5 -20 120 184 10 18 0 +49 42 12 -30 79 158 10 23 0 +50 72 35 30 104 157 10 0 96 +51 55 20 19 69 126 10 0 80 +52 25 30 3 36 97 10 0 24 +53 20 50 -19 57 154 10 88 0 +54 55 60 -23 127 180 10 94 0 +55 30 60 16 95 214 0 0 104 +56 50 35 -10 88 201 10 21 0 +57 30 25 -16 82 139 10 65 0 +58 15 10 -16 56 182 10 75 0 +59 10 20 -13 42 125 10 87 0 +60 15 60 17 137 202 10 0 68 +61 45 65 9 55 106 10 0 90 +62 65 35 3 29 158 10 0 76 +63 65 20 6 39 108 10 0 89 +64 45 30 17 20 139 10 0 25 +65 35 40 16 11 140 10 0 57 +66 41 37 -40 92 203 10 22 0 +67 64 42 -14 28 141 10 71 0 +68 40 60 -17 100 217 10 60 0 +69 31 52 27 9 134 10 0 79 +70 35 69 -5 60 210 10 73 0 +71 65 55 14 52 107 10 0 67 +72 63 65 8 27 101 10 0 93 +73 2 60 5 65 118 10 0 70 +74 20 20 8 72 193 0 0 105 +75 5 5 16 60 117 10 0 58 +76 60 12 -3 42 143 10 62 0 +77 23 3 -35 52 180 10 97 0 +78 8 56 -9 46 163 10 98 0 +79 6 68 -27 54 153 10 69 0 +80 47 47 -19 97 222 10 51 0 +81 49 58 10 80 121 0 0 106 +82 27 43 9 26 87 10 0 99 +83 37 31 14 19 87 10 0 86 +84 57 29 -6 62 159 10 95 0 +85 63 23 -14 76 127 10 92 0 +86 21 24 -14 77 126 10 83 0 +87 12 24 13 68 141 10 0 59 +88 24 58 19 24 139 10 0 53 +89 67 5 -6 105 177 10 63 0 +90 37 47 -9 74 127 10 61 0 +91 49 42 13 151 212 0 0 102 +92 53 43 14 14 155 10 0 85 +93 61 52 -8 69 208 10 72 0 +94 57 48 23 86 133 10 0 54 +95 56 37 6 20 84 10 0 84 +96 55 54 -30 121 172 10 50 0 +97 4 18 35 112 157 10 0 77 +98 26 52 9 30 91 10 0 78 +99 26 35 -9 37 146 10 82 0 +100 31 67 -40 66 210 10 4 0 +101 85 25 -10 51 178 10 33 0 +102 49 42 -13 151 212 10 91 0 +103 15 75 -20 69 118 10 7 0 +104 30 60 -16 95 214 10 55 0 +105 20 20 -8 72 193 10 74 0 +106 49 58 -10 80 121 10 81 0 diff --git a/jsprit-instances/instances/lilim/lrc108.txt b/jsprit-instances/instances/lilim/lrc108.txt new file mode 100644 index 00000000..28e1eaa1 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc108.txt @@ -0,0 +1,106 @@ +25 200 1 +0 40 50 0 0 240 0 0 0 +1 25 85 20 49 191 0 0 103 +2 22 75 -20 30 168 10 6 0 +3 22 85 10 95 152 10 0 4 +4 20 80 -10 69 193 10 3 0 +5 20 85 20 40 189 10 0 45 +6 18 75 20 60 159 10 0 2 +7 15 75 20 54 133 0 0 104 +8 15 80 -30 67 144 10 79 0 +9 10 35 -10 57 154 10 14 0 +10 10 40 -20 106 161 10 15 0 +11 8 40 -20 33 152 10 16 0 +12 8 45 20 32 148 10 0 17 +13 5 35 -10 53 191 10 47 0 +14 5 45 10 35 194 10 0 9 +15 2 40 20 39 163 10 0 10 +16 0 40 20 41 141 10 0 11 +17 0 45 -20 51 189 10 12 0 +18 44 5 -19 73 130 10 51 0 +19 42 10 -31 40 148 10 76 0 +20 42 15 10 94 179 0 0 101 +21 40 5 -10 45 161 10 24 0 +22 40 15 40 64 149 10 0 23 +23 38 5 -40 45 164 10 22 0 +24 38 15 10 51 194 10 0 21 +25 35 5 20 45 183 10 0 77 +26 95 30 30 90 169 10 0 93 +27 95 35 20 57 172 10 0 31 +28 92 30 -10 55 174 10 33 0 +29 90 35 10 52 174 10 0 34 +30 88 30 -10 52 147 10 32 0 +31 88 35 -20 50 172 10 27 0 +32 87 30 10 61 178 10 0 30 +33 85 25 10 51 178 10 0 28 +34 85 35 -10 83 168 10 29 0 +35 67 85 -30 57 185 10 40 0 +36 65 85 -10 43 186 10 42 0 +37 65 82 -20 95 182 10 43 0 +38 62 80 30 38 141 10 0 39 +39 60 80 -30 36 193 10 38 0 +40 60 85 30 61 138 10 0 35 +41 58 75 20 49 164 10 0 44 +42 55 80 10 33 180 10 0 36 +43 55 85 20 100 185 10 0 37 +44 55 82 -20 35 142 10 41 0 +45 20 82 -20 37 192 10 5 0 +46 18 80 -5 71 184 10 73 0 +47 2 45 10 38 191 10 0 13 +48 42 5 10 50 184 10 0 66 +49 42 12 -14 99 138 10 83 0 +50 72 35 30 83 178 10 0 56 +51 55 20 19 45 150 10 0 18 +52 25 30 3 25 150 10 0 59 +53 20 50 5 68 143 10 0 60 +54 55 60 16 107 200 10 0 96 +55 30 60 -6 95 214 10 90 0 +56 50 35 -30 91 198 10 50 0 +57 30 25 -16 56 165 10 65 0 +58 15 10 20 51 182 10 0 74 +59 10 20 -3 42 187 10 52 0 +60 15 60 -5 62 203 10 53 0 +61 45 65 9 37 124 10 0 94 +62 65 35 -9 29 168 10 67 0 +63 65 20 6 39 190 10 0 91 +64 45 30 17 20 139 10 0 89 +65 35 40 16 11 150 10 0 57 +66 41 37 -10 97 198 10 48 0 +67 64 42 9 31 138 10 0 62 +68 40 60 -27 101 216 10 69 0 +69 31 52 27 9 139 10 0 68 +70 35 69 23 30 210 10 0 100 +71 65 55 14 30 129 10 0 72 +72 63 65 -14 27 202 10 71 0 +73 2 60 5 46 137 10 0 46 +74 20 20 -20 71 193 10 58 0 +75 5 5 -35 57 165 10 97 0 +76 60 12 31 48 131 10 0 19 +77 23 3 -20 49 180 10 25 0 +78 8 56 -9 47 162 10 98 0 +79 6 68 30 65 142 10 0 8 +80 47 47 -18 93 222 10 84 0 +81 49 58 -19 78 123 10 88 0 +82 27 43 9 14 140 10 0 86 +83 37 31 14 19 172 10 0 49 +84 57 29 18 73 148 10 0 80 +85 63 23 -14 59 144 10 92 0 +86 21 24 -9 63 140 10 82 0 +87 12 24 -15 91 118 10 99 0 +88 24 58 19 27 136 10 0 81 +89 67 5 -17 52 177 10 64 0 +90 37 47 6 53 148 10 0 55 +91 49 42 -6 89 217 10 63 0 +92 53 43 14 14 177 10 0 85 +93 61 52 -30 50 208 10 26 0 +94 57 48 -9 76 143 10 61 0 +95 56 37 6 20 159 0 0 102 +96 55 54 -16 105 188 10 54 0 +97 4 18 35 104 165 10 0 75 +98 26 52 9 14 136 10 0 78 +99 26 35 15 42 141 10 0 87 +100 31 67 -23 43 210 10 70 0 +101 42 15 -10 94 179 10 20 0 +102 56 37 -6 20 159 10 95 0 +103 25 85 -20 49 191 10 1 0 +104 15 75 -20 54 133 10 7 0 diff --git a/jsprit-instances/instances/lilim/lrc201.txt b/jsprit-instances/instances/lilim/lrc201.txt new file mode 100644 index 00000000..893ac8f0 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc201.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 -10 673 793 10 14 0 +2 22 75 30 152 272 10 0 98 +3 22 85 10 471 591 0 0 101 +4 20 80 -19 644 764 10 59 0 +5 20 85 20 73 193 10 0 88 +6 18 75 -20 388 508 10 12 0 +7 15 75 -16 300 420 10 65 0 +8 15 80 10 367 487 10 0 46 +9 10 35 -13 371 491 10 87 0 +10 10 40 -3 519 639 10 62 0 +11 8 40 40 195 315 10 0 68 +12 8 45 20 223 343 10 0 6 +13 5 35 -23 653 773 10 57 0 +14 5 45 10 35 155 10 0 1 +15 2 40 20 174 294 10 0 55 +16 0 40 20 255 375 10 0 73 +17 0 45 20 703 823 10 0 100 +18 44 5 -9 335 455 10 82 0 +19 42 10 40 254 374 10 0 51 +20 42 15 10 537 657 10 0 54 +21 40 5 -30 215 335 10 23 0 +22 40 15 -2 375 495 10 85 0 +23 38 5 30 201 321 10 0 21 +24 38 15 -25 681 801 10 89 0 +25 35 5 -10 784 904 10 48 0 +26 95 30 -20 529 649 10 41 0 +27 95 35 20 146 266 10 0 99 +28 92 30 10 149 269 10 0 67 +29 90 35 10 194 314 10 0 30 +30 88 30 -10 246 366 10 29 0 +31 88 35 20 165 285 10 0 90 +32 87 30 -30 621 741 10 38 0 +33 85 25 10 80 200 10 0 71 +34 85 35 -10 487 607 10 39 0 +35 67 85 -3 657 777 10 52 0 +36 65 85 40 43 163 10 0 72 +37 65 82 10 557 677 10 0 80 +38 62 80 30 278 398 10 0 32 +39 60 80 10 64 184 10 0 34 +40 60 85 -10 329 449 10 45 0 +41 58 75 20 376 496 10 0 26 +42 55 80 10 33 153 10 0 44 +43 55 85 -17 574 694 10 64 0 +44 55 82 -10 217 337 10 42 0 +45 20 82 10 37 157 10 0 40 +46 18 80 -10 489 609 10 8 0 +47 2 45 10 105 225 10 0 78 +48 42 5 10 732 852 10 0 25 +49 42 12 10 440 560 10 0 56 +50 72 35 -10 507 627 10 81 0 +51 55 20 -40 326 446 10 19 0 +52 25 30 3 175 295 10 0 35 +53 20 50 -14 375 495 10 92 0 +54 55 60 -10 601 721 10 20 0 +55 30 60 -20 599 719 10 15 0 +56 50 35 -10 557 677 10 49 0 +57 30 25 23 397 517 10 0 13 +58 15 10 -7 782 902 10 77 0 +59 10 20 19 42 162 10 0 4 +60 15 60 -35 694 814 10 97 0 +61 45 65 9 258 378 10 0 94 +62 65 35 3 167 287 10 0 10 +63 65 20 -6 39 159 10 95 0 +64 45 30 17 191 311 10 0 43 +65 35 40 16 11 131 10 0 7 +66 41 37 16 566 686 10 0 93 +67 64 42 -10 268 388 10 28 0 +68 40 60 -40 612 732 10 11 0 +69 31 52 27 157 277 10 0 76 +70 35 69 23 810 930 0 0 102 +71 65 55 -10 241 361 10 33 0 +72 63 65 -40 60 180 10 36 0 +73 2 60 -20 286 406 10 16 0 +74 20 20 -28 645 765 10 86 0 +75 5 5 16 232 352 10 0 79 +76 60 12 -27 268 388 10 69 0 +77 23 3 7 764 884 10 0 58 +78 8 56 -10 365 485 10 47 0 +79 6 68 -16 352 472 10 75 0 +80 47 47 -10 822 942 10 37 0 +81 49 58 10 355 475 10 0 50 +82 27 43 9 152 272 10 0 18 +83 37 31 14 105 225 10 0 84 +84 57 29 -14 395 515 10 83 0 +85 63 23 2 344 464 10 0 22 +86 21 24 28 349 469 10 0 74 +87 12 24 13 359 479 10 0 9 +88 24 58 -20 260 380 10 5 0 +89 67 5 25 713 833 10 0 24 +90 37 47 -20 359 479 10 31 0 +91 49 42 -26 719 839 10 96 0 +92 53 43 14 14 134 10 0 53 +93 61 52 -16 808 928 10 66 0 +94 57 48 -9 392 512 10 61 0 +95 56 37 6 100 220 10 0 63 +96 55 54 26 562 682 10 0 91 +97 4 18 35 547 667 10 0 60 +98 26 52 -30 172 292 10 2 0 +99 26 35 -20 308 428 10 27 0 +100 31 67 -20 810 930 10 17 0 +101 22 85 -10 471 591 10 3 0 +102 35 69 -23 810 930 10 70 0 diff --git a/jsprit-instances/instances/lilim/lrc202.txt b/jsprit-instances/instances/lilim/lrc202.txt new file mode 100644 index 00000000..6f628a5b --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc202.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 -20 0 911 10 5 0 +2 22 75 -10 0 919 10 8 0 +3 22 85 10 0 910 10 0 44 +4 20 80 40 644 764 10 0 70 +5 20 85 20 0 909 10 0 1 +6 18 75 20 388 508 10 0 43 +7 15 75 -10 0 914 10 13 0 +8 15 80 10 367 487 10 0 2 +9 10 35 -28 371 491 10 86 0 +10 10 40 30 519 639 10 0 97 +11 8 40 -10 195 315 10 47 0 +12 8 45 20 0 917 10 0 48 +13 5 35 10 653 773 10 0 7 +14 5 45 10 35 155 10 0 60 +15 2 40 20 174 294 10 0 100 +16 0 40 -5 255 375 10 73 0 +17 0 45 -13 703 823 10 87 0 +18 44 5 20 335 455 10 0 51 +19 42 10 40 254 374 10 0 59 +20 42 15 -8 537 657 10 72 0 +21 40 5 -10 0 905 10 32 0 +22 40 15 -16 375 495 10 65 0 +23 38 5 -27 201 321 10 69 0 +24 38 15 -20 681 801 10 41 0 +25 35 5 -9 784 904 10 67 0 +26 95 30 -10 0 891 10 28 0 +27 95 35 20 146 266 10 0 91 +28 92 30 10 149 269 10 0 26 +29 90 35 -10 194 314 10 33 0 +30 88 30 10 246 366 10 0 83 +31 88 35 20 0 899 10 0 34 +32 87 30 10 621 741 10 0 21 +33 85 25 10 80 200 10 0 29 +34 85 35 -20 0 902 10 31 0 +35 67 85 -10 657 777 10 46 0 +36 65 85 40 43 163 10 0 99 +37 65 82 -10 0 909 10 42 0 +38 62 80 -6 278 398 10 95 0 +39 60 80 10 64 184 10 0 61 +40 60 85 30 329 449 10 0 49 +41 58 75 20 376 496 10 0 24 +42 55 80 10 33 153 10 0 37 +43 55 85 -20 574 694 10 6 0 +44 55 82 -10 217 337 10 3 0 +45 20 82 -9 37 157 10 98 0 +46 18 80 10 489 609 10 0 35 +47 2 45 10 105 225 10 0 11 +48 42 5 -20 0 904 10 12 0 +49 42 12 -30 440 560 10 40 0 +50 72 35 -10 0 914 10 81 0 +51 55 20 -20 326 446 10 18 0 +52 25 30 -31 0 925 10 76 0 +53 20 50 5 375 495 10 0 94 +54 55 60 -16 601 721 10 55 0 +55 30 60 16 599 719 10 0 54 +56 50 35 -6 557 677 10 90 0 +57 30 25 -17 397 517 10 64 0 +58 15 10 20 782 902 0 0 102 +59 10 20 -40 0 907 10 19 0 +60 15 60 -10 694 814 10 14 0 +61 45 65 -10 258 378 10 39 0 +62 65 35 3 167 287 10 0 77 +63 65 20 -14 39 159 10 92 0 +64 45 30 17 191 311 10 0 57 +65 35 40 16 11 131 10 0 22 +66 41 37 -18 566 686 10 84 0 +67 64 42 9 268 388 10 0 25 +68 40 60 21 612 732 0 0 101 +69 31 52 27 157 277 10 0 23 +70 35 69 -40 810 930 10 4 0 +71 65 55 -2 241 361 10 85 0 +72 63 65 8 0 922 10 0 20 +73 2 60 5 286 406 10 0 16 +74 20 20 -9 645 765 10 82 0 +75 5 5 -25 0 892 10 89 0 +76 60 12 31 268 388 10 0 52 +77 23 3 -3 764 884 10 62 0 +78 8 56 27 365 485 10 0 96 +79 6 68 -19 352 472 10 88 0 +80 47 47 -3 822 942 10 93 0 +81 49 58 10 355 475 10 0 50 +82 27 43 9 0 935 10 0 74 +83 37 31 -10 0 930 10 30 0 +84 57 29 18 395 515 10 0 66 +85 63 23 2 0 914 10 0 71 +86 21 24 28 349 469 10 0 9 +87 12 24 13 359 479 10 0 17 +88 24 58 19 260 380 10 0 79 +89 67 5 25 713 833 10 0 75 +90 37 47 6 359 479 10 0 56 +91 49 42 -20 0 937 10 27 0 +92 53 43 14 14 134 10 0 63 +93 61 52 3 808 928 10 0 80 +94 57 48 -5 0 932 10 53 0 +95 56 37 6 0 929 10 0 38 +96 55 54 -27 0 934 10 78 0 +97 4 18 -30 547 667 10 10 0 +98 26 52 9 0 935 10 0 45 +99 26 35 -40 308 428 10 36 0 +100 31 67 -20 810 930 10 15 0 +101 40 60 -21 612 732 10 68 0 +102 15 10 -20 782 902 10 58 0 diff --git a/jsprit-instances/instances/lilim/lrc203.txt b/jsprit-instances/instances/lilim/lrc203.txt new file mode 100644 index 00000000..44ae0032 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc203.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 20 0 911 10 0 35 +2 22 75 -10 0 919 10 45 0 +3 22 85 10 0 910 10 0 43 +4 20 80 40 644 764 0 0 101 +5 20 85 -10 0 909 10 44 0 +6 18 75 -20 388 508 10 41 0 +7 15 75 20 0 914 10 0 11 +8 15 80 -30 367 487 10 38 0 +9 10 35 -10 371 491 10 48 0 +10 10 40 -23 519 639 10 57 0 +11 8 40 -20 195 315 10 7 0 +12 8 45 -20 0 917 10 18 0 +13 5 35 -5 653 773 10 73 0 +14 5 45 10 0 914 10 0 77 +15 2 40 20 174 294 10 0 88 +16 0 40 -3 0 908 10 52 0 +17 0 45 -10 703 823 10 47 0 +18 44 5 20 0 904 10 0 12 +19 42 10 40 0 909 10 0 56 +20 42 15 -10 0 914 10 30 0 +21 40 5 -17 0 905 10 64 0 +22 40 15 -10 375 495 10 29 0 +23 38 5 30 201 321 10 0 87 +24 38 15 10 0 914 10 0 83 +25 35 5 -20 784 904 10 58 0 +26 95 30 -30 0 891 10 50 0 +27 95 35 20 146 266 10 0 82 +28 92 30 -10 0 894 10 33 0 +29 90 35 10 0 897 10 0 22 +30 88 30 10 246 366 10 0 20 +31 88 35 20 0 899 10 0 76 +32 87 30 -16 0 898 10 65 0 +33 85 25 10 80 200 10 0 28 +34 85 35 -6 0 902 10 90 0 +35 67 85 -20 657 777 10 1 0 +36 65 85 -10 43 163 10 81 0 +37 65 82 -10 0 909 10 46 0 +38 62 80 30 278 398 10 0 8 +39 60 80 10 64 184 10 0 40 +40 60 85 -10 329 449 10 39 0 +41 58 75 20 376 496 10 0 6 +42 55 80 10 33 153 10 0 61 +43 55 85 -10 0 911 10 3 0 +44 55 82 10 217 337 10 0 5 +45 20 82 10 37 157 10 0 2 +46 18 80 10 0 912 10 0 37 +47 2 45 10 0 911 10 0 17 +48 42 5 10 0 904 10 0 9 +49 42 12 10 440 560 10 0 100 +50 72 35 30 0 914 10 0 26 +51 55 20 -2 0 916 10 85 0 +52 25 30 3 0 925 10 0 16 +53 20 50 -27 375 495 10 69 0 +54 55 60 16 0 931 10 0 60 +55 30 60 16 599 719 10 0 70 +56 50 35 -40 557 677 10 19 0 +57 30 25 23 0 923 10 0 10 +58 15 10 20 782 902 10 0 25 +59 10 20 19 0 907 10 0 97 +60 15 60 -16 0 923 10 54 0 +61 45 65 -10 0 934 10 42 0 +62 65 35 3 167 287 10 0 89 +63 65 20 6 0 910 10 0 98 +64 45 30 17 191 311 10 0 21 +65 35 40 16 11 131 10 0 32 +66 41 37 -18 566 686 10 84 0 +67 64 42 9 268 388 10 0 68 +68 40 60 -9 612 732 10 67 0 +69 31 52 27 157 277 10 0 53 +70 35 69 -16 810 930 10 55 0 +71 65 55 14 0 924 10 0 96 +72 63 65 8 0 922 10 0 94 +73 2 60 5 0 910 10 0 13 +74 20 20 -15 645 765 10 99 0 +75 5 5 -30 0 892 10 79 0 +76 60 12 -20 268 388 10 31 0 +77 23 3 -10 764 884 10 14 0 +78 8 56 -28 365 485 10 86 0 +79 6 68 30 352 472 10 0 75 +80 47 47 -3 822 942 10 93 0 +81 49 58 10 0 937 10 0 36 +82 27 43 -20 0 935 10 27 0 +83 37 31 -10 0 930 10 24 0 +84 57 29 18 395 515 10 0 66 +85 63 23 2 0 914 10 0 51 +86 21 24 28 0 917 10 0 78 +87 12 24 -30 359 479 10 23 0 +88 24 58 -20 260 380 10 15 0 +89 67 5 -3 0 897 10 62 0 +90 37 47 6 0 945 10 0 34 +91 49 42 13 0 937 10 0 95 +92 53 43 14 14 134 0 0 102 +93 61 52 3 808 928 10 0 80 +94 57 48 -8 0 932 10 72 0 +95 56 37 -13 0 929 10 91 0 +96 55 54 -14 0 934 10 71 0 +97 4 18 -19 0 901 10 59 0 +98 26 52 -6 0 935 10 63 0 +99 26 35 15 308 428 10 0 74 +100 31 67 -10 810 930 10 49 0 +101 20 80 -40 644 764 10 4 0 +102 53 43 -14 14 134 10 92 0 diff --git a/jsprit-instances/instances/lilim/lrc204.txt b/jsprit-instances/instances/lilim/lrc204.txt new file mode 100644 index 00000000..7bc0beb8 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc204.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 20 0 911 0 0 101 +2 22 75 -20 0 919 10 7 0 +3 22 85 10 0 910 10 0 5 +4 20 80 -27 644 764 10 78 0 +5 20 85 -10 0 909 10 3 0 +6 18 75 -17 0 916 10 60 0 +7 15 75 20 0 914 10 0 2 +8 15 80 -20 367 487 10 43 0 +9 10 35 -3 371 491 10 52 0 +10 10 40 -20 0 918 10 17 0 +11 8 40 -9 195 315 10 98 0 +12 8 45 20 0 917 10 0 15 +13 5 35 -9 653 773 10 82 0 +14 5 45 -27 0 914 10 69 0 +15 2 40 -20 174 294 10 12 0 +16 0 40 20 0 908 10 0 59 +17 0 45 20 0 909 10 0 10 +18 44 5 20 0 904 10 0 71 +19 42 10 40 0 909 10 0 48 +20 42 15 -19 0 914 10 56 0 +21 40 5 -14 0 905 10 92 0 +22 40 15 40 0 915 10 0 85 +23 38 5 30 201 321 10 0 30 +24 38 15 -5 0 914 10 53 0 +25 35 5 -13 784 904 10 87 0 +26 95 30 30 0 891 10 0 96 +27 95 35 -18 0 892 10 84 0 +28 92 30 10 0 894 10 0 31 +29 90 35 10 0 897 10 0 94 +30 88 30 -30 0 898 10 23 0 +31 88 35 -10 0 899 10 28 0 +32 87 30 -6 0 898 10 95 0 +33 85 25 10 0 898 10 0 93 +34 85 35 -25 0 902 10 89 0 +35 67 85 20 0 905 10 0 45 +36 65 85 -20 0 906 10 41 0 +37 65 82 10 0 909 10 0 44 +38 62 80 30 278 398 10 0 42 +39 60 80 -8 0 913 10 72 0 +40 60 85 -16 0 909 10 54 0 +41 58 75 20 0 919 10 0 36 +42 55 80 -30 0 916 10 38 0 +43 55 85 20 0 911 10 0 8 +44 55 82 -10 217 337 10 37 0 +45 20 82 -20 0 912 10 35 0 +46 18 80 10 0 912 10 0 100 +47 2 45 10 0 911 10 0 58 +48 42 5 -40 0 904 10 19 0 +49 42 12 -13 0 911 10 80 0 +50 72 35 -9 0 914 10 67 0 +51 55 20 -3 0 916 10 62 0 +52 25 30 3 0 925 10 0 9 +53 20 50 5 375 495 10 0 24 +54 55 60 16 0 931 10 0 40 +55 30 60 -19 599 719 10 88 0 +56 50 35 19 0 931 10 0 20 +57 30 25 23 0 923 10 0 90 +58 15 10 -10 782 902 10 47 0 +59 10 20 -20 0 907 10 16 0 +60 15 60 17 0 923 10 0 6 +61 45 65 -5 0 934 10 73 0 +62 65 35 3 167 287 10 0 51 +63 65 20 -17 0 910 10 64 0 +64 45 30 17 0 929 10 0 63 +65 35 40 -35 0 938 10 97 0 +66 41 37 -8 0 936 10 74 0 +67 64 42 9 268 388 10 0 50 +68 40 60 -23 0 940 10 70 0 +69 31 52 27 157 277 10 0 14 +70 35 69 23 0 930 10 0 68 +71 65 55 -20 0 924 10 18 0 +72 63 65 8 0 922 10 0 39 +73 2 60 5 0 910 10 0 61 +74 20 20 8 645 765 10 0 66 +75 5 5 -15 0 892 10 99 0 +76 60 12 -13 268 388 10 91 0 +77 23 3 -28 764 884 10 86 0 +78 8 56 27 0 917 10 0 4 +79 6 68 -10 352 472 10 81 0 +80 47 47 13 0 942 10 0 49 +81 49 58 10 0 937 10 0 79 +82 27 43 9 0 935 10 0 13 +83 37 31 14 0 930 0 0 102 +84 57 29 18 395 515 10 0 27 +85 63 23 -40 0 914 10 22 0 +86 21 24 28 0 917 10 0 77 +87 12 24 13 359 479 10 0 25 +88 24 58 19 0 932 10 0 55 +89 67 5 25 0 897 10 0 34 +90 37 47 -23 0 945 10 57 0 +91 49 42 13 0 937 10 0 76 +92 53 43 14 14 134 10 0 21 +93 61 52 -10 0 928 10 33 0 +94 57 48 -10 0 932 10 29 0 +95 56 37 6 0 929 10 0 32 +96 55 54 -30 0 934 10 26 0 +97 4 18 35 0 901 10 0 65 +98 26 52 9 0 935 10 0 11 +99 26 35 15 308 428 10 0 75 +100 31 67 -10 810 930 10 46 0 +101 25 85 -20 0 911 10 1 0 +102 37 31 -14 0 930 10 83 0 diff --git a/jsprit-instances/instances/lilim/lrc205.txt b/jsprit-instances/instances/lilim/lrc205.txt new file mode 100644 index 00000000..65c26af5 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc205.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 -10 431 911 10 8 0 +2 22 75 30 30 510 10 0 39 +3 22 85 -5 291 771 10 73 0 +4 20 80 -27 674 734 10 78 0 +5 20 85 20 40 520 10 0 42 +6 18 75 20 393 502 10 0 70 +7 15 75 -30 120 600 10 79 0 +8 15 80 10 397 457 10 0 1 +9 10 35 20 401 461 10 0 80 +10 10 40 -16 535 622 10 75 0 +11 8 40 40 225 285 10 0 16 +12 8 45 -27 43 523 10 69 0 +13 5 35 -10 683 743 10 49 0 +14 5 45 -9 35 366 10 98 0 +15 2 40 20 204 264 10 0 47 +16 0 40 -40 204 425 10 11 0 +17 0 45 -20 698 827 10 27 0 +18 44 5 -10 306 483 10 21 0 +19 42 10 40 199 428 10 0 52 +20 42 15 10 494 699 10 0 60 +21 40 5 10 45 525 10 0 18 +22 40 15 -10 383 486 10 30 0 +23 38 5 -17 231 291 10 64 0 +24 38 15 -9 609 872 10 67 0 +25 35 5 -30 821 881 10 50 0 +26 95 30 30 349 829 10 0 48 +27 95 35 20 138 273 10 0 17 +28 92 30 10 78 339 10 0 74 +29 90 35 10 132 375 10 0 76 +30 88 30 10 252 359 10 0 22 +31 88 35 20 50 530 10 0 51 +32 87 30 10 562 799 10 0 77 +33 85 25 10 71 208 10 0 84 +34 85 35 -8 307 787 10 72 0 +35 67 85 -19 655 778 10 59 0 +36 65 85 40 43 186 10 0 82 +37 65 82 10 377 857 10 0 96 +38 62 80 -10 308 368 10 44 0 +39 60 80 -30 46 201 10 2 0 +40 60 85 -23 339 438 10 94 0 +41 58 75 20 377 494 10 0 56 +42 55 80 -20 33 166 10 5 0 +43 55 85 20 531 736 10 0 91 +44 55 82 10 247 307 10 0 38 +45 20 82 10 37 177 10 0 71 +46 18 80 -19 432 665 10 88 0 +47 2 45 -20 38 322 10 15 0 +48 42 5 -30 424 904 10 26 0 +49 42 12 10 460 539 10 0 13 +50 72 35 30 327 807 10 0 25 +51 55 20 -20 273 498 10 31 0 +52 25 30 -40 25 505 10 19 0 +53 20 50 5 405 465 10 0 58 +54 55 60 -15 554 767 10 99 0 +55 30 60 16 629 689 10 0 93 +56 50 35 -20 560 673 10 41 0 +57 30 25 -16 342 571 10 65 0 +58 15 10 -5 842 902 10 53 0 +59 10 20 19 42 522 10 0 35 +60 15 60 -10 623 884 10 20 0 +61 45 65 9 214 421 10 0 90 +62 65 35 3 197 257 10 0 89 +63 65 20 6 39 316 10 0 85 +64 45 30 17 191 310 10 0 23 +65 35 40 16 11 140 10 0 57 +66 41 37 -10 570 681 10 81 0 +67 64 42 9 298 358 10 0 24 +68 40 60 -13 613 730 10 87 0 +69 31 52 27 187 247 10 0 12 +70 35 69 -20 780 930 10 6 0 +71 65 55 -10 191 410 10 45 0 +72 63 65 8 27 507 10 0 34 +73 2 60 5 240 451 10 0 3 +74 20 20 -10 675 735 10 28 0 +75 5 5 16 57 537 10 0 10 +76 60 12 -10 298 358 10 29 0 +77 23 3 -10 794 854 10 32 0 +78 8 56 27 366 483 10 0 4 +79 6 68 30 382 442 10 0 7 +80 47 47 -20 817 942 10 9 0 +81 49 58 10 332 497 10 0 66 +82 27 43 -40 14 494 10 36 0 +83 37 31 14 19 499 10 0 86 +84 57 29 -10 425 485 10 33 0 +85 63 23 -6 164 644 10 63 0 +86 21 24 -14 310 507 10 83 0 +87 12 24 13 389 449 10 0 68 +88 24 58 19 262 377 10 0 46 +89 67 5 -3 611 897 10 62 0 +90 37 47 -9 311 526 10 61 0 +91 49 42 -20 457 937 10 43 0 +92 53 43 14 14 74 10 0 95 +93 61 52 -16 789 928 10 55 0 +94 57 48 23 212 692 10 0 40 +95 56 37 -14 20 500 10 92 0 +96 55 54 -10 382 862 10 37 0 +97 4 18 35 516 697 0 0 102 +98 26 52 9 14 494 10 0 14 +99 26 35 15 338 398 10 0 54 +100 31 67 3 870 930 0 0 101 +101 31 67 -3 870 930 10 100 0 +102 4 18 -35 516 697 10 97 0 diff --git a/jsprit-instances/instances/lilim/lrc206.txt b/jsprit-instances/instances/lilim/lrc206.txt new file mode 100644 index 00000000..aa08b5c9 --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc206.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 -20 613 853 10 41 0 +2 22 75 30 92 332 10 0 71 +3 22 85 -10 411 651 10 8 0 +4 20 80 40 584 824 10 0 37 +5 20 85 20 40 280 10 0 45 +6 18 75 -10 328 568 10 39 0 +7 15 75 -30 240 480 10 38 0 +8 15 80 10 307 547 10 0 3 +9 10 35 -35 311 551 10 97 0 +10 10 40 -13 459 699 10 87 0 +11 8 40 40 135 375 10 0 59 +12 8 45 20 163 403 10 0 66 +13 5 35 -31 593 833 10 76 0 +14 5 45 10 35 275 10 0 84 +15 2 40 20 114 354 10 0 81 +16 0 40 -27 195 435 10 69 0 +17 0 45 20 643 883 10 0 70 +18 44 5 -10 275 515 10 33 0 +19 42 10 40 194 434 10 0 49 +20 42 15 10 477 717 10 0 24 +21 40 5 -20 155 395 10 31 0 +22 40 15 -10 315 555 10 28 0 +23 38 5 -6 141 381 10 63 0 +24 38 15 -10 621 861 10 20 0 +25 35 5 -30 664 904 10 26 0 +26 95 30 30 469 709 10 0 25 +27 95 35 -14 86 326 10 83 0 +28 92 30 10 89 329 10 0 22 +29 90 35 -14 134 374 10 92 0 +30 88 30 10 186 426 10 0 85 +31 88 35 20 105 345 10 0 21 +32 87 30 10 561 801 0 0 101 +33 85 25 10 51 291 10 0 18 +34 85 35 30 427 667 10 0 89 +35 67 85 -19 597 837 10 88 0 +36 65 85 40 43 283 10 0 53 +37 65 82 -40 497 737 10 4 0 +38 62 80 30 218 458 10 0 7 +39 60 80 10 36 276 10 0 6 +40 60 85 -10 269 509 10 42 0 +41 58 75 20 316 556 10 0 1 +42 55 80 10 33 273 10 0 40 +43 55 85 20 514 754 10 0 80 +44 55 82 10 157 397 0 0 102 +45 20 82 -20 37 277 10 5 0 +46 18 80 10 429 669 10 0 96 +47 2 45 10 45 285 10 0 90 +48 42 5 10 664 904 10 0 58 +49 42 12 -40 380 620 10 19 0 +50 72 35 -17 447 687 10 64 0 +51 55 20 19 266 506 10 0 55 +52 25 30 3 115 355 10 0 94 +53 20 50 -40 315 555 10 36 0 +54 55 60 16 541 781 10 0 93 +55 30 60 -19 539 779 10 51 0 +56 50 35 -9 497 737 10 82 0 +57 30 25 23 337 577 10 0 100 +58 15 10 -10 662 902 10 48 0 +59 10 20 -40 42 282 10 11 0 +60 15 60 17 634 874 10 0 68 +61 45 65 9 198 438 10 0 73 +62 65 35 3 107 347 10 0 99 +63 65 20 6 39 279 10 0 23 +64 45 30 17 131 371 10 0 50 +65 35 40 16 11 251 10 0 95 +66 41 37 -20 506 746 10 12 0 +67 64 42 -16 208 448 10 75 0 +68 40 60 -17 552 792 10 60 0 +69 31 52 27 97 337 10 0 16 +70 35 69 -20 690 930 10 17 0 +71 65 55 -30 181 421 10 2 0 +72 63 65 8 27 267 10 0 91 +73 2 60 -9 226 466 10 61 0 +74 20 20 -7 585 825 10 77 0 +75 5 5 16 172 412 10 0 67 +76 60 12 31 208 448 10 0 13 +77 23 3 7 660 900 10 0 74 +78 8 56 27 305 545 10 0 79 +79 6 68 -27 292 532 10 78 0 +80 47 47 -20 702 942 10 43 0 +81 49 58 -20 295 535 10 15 0 +82 27 43 9 92 332 10 0 56 +83 37 31 14 45 285 10 0 27 +84 57 29 -10 335 575 10 14 0 +85 63 23 -10 284 524 10 30 0 +86 21 24 -9 289 529 10 98 0 +87 12 24 13 299 539 10 0 10 +88 24 58 19 200 440 10 0 35 +89 67 5 -30 653 893 10 34 0 +90 37 47 -10 299 539 10 47 0 +91 49 42 -8 659 899 10 72 0 +92 53 43 14 14 254 10 0 29 +93 61 52 -16 688 928 10 54 0 +94 57 48 -3 332 572 10 52 0 +95 56 37 -16 40 280 10 65 0 +96 55 54 -10 502 742 10 46 0 +97 4 18 35 487 727 10 0 9 +98 26 52 9 112 352 10 0 86 +99 26 35 -3 248 488 10 62 0 +100 31 67 -23 690 930 10 57 0 +101 87 30 -10 561 801 10 32 0 +102 55 82 -10 157 397 10 44 0 diff --git a/jsprit-instances/instances/lilim/lrc207.txt b/jsprit-instances/instances/lilim/lrc207.txt new file mode 100644 index 00000000..8307ea9f --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc207.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 -10 591 874 10 30 0 +2 22 75 30 73 350 10 0 5 +3 22 85 -30 473 588 10 40 0 +4 20 80 -6 418 913 10 63 0 +5 20 85 -30 40 390 10 2 0 +6 18 75 20 249 646 10 0 7 +7 15 75 -20 281 438 10 6 0 +8 15 80 -9 272 581 10 61 0 +9 10 35 20 236 625 10 0 74 +10 10 40 -10 470 687 10 13 0 +11 8 40 -10 33 510 10 45 0 +12 8 45 20 166 399 10 0 57 +13 5 35 10 359 911 10 0 10 +14 5 45 10 35 457 10 0 68 +15 2 40 -10 39 538 10 47 0 +16 0 40 20 214 415 10 0 87 +17 0 45 -27 359 909 10 69 0 +18 44 5 20 338 451 10 0 94 +19 42 10 40 205 422 10 0 51 +20 42 15 10 511 682 10 0 60 +21 40 5 10 158 391 10 0 84 +22 40 15 40 263 606 10 0 97 +23 38 5 -3 45 522 10 52 0 +24 38 15 -30 598 883 10 26 0 +25 35 5 20 348 904 0 0 102 +26 95 30 30 509 668 10 0 24 +27 95 35 -2 57 664 10 85 0 +28 92 30 10 68 349 10 0 90 +29 90 35 10 131 376 10 0 35 +30 88 30 10 114 497 10 0 1 +31 88 35 20 102 347 10 0 81 +32 87 30 -3 564 797 10 93 0 +33 85 25 10 51 673 10 0 54 +34 85 35 -9 462 631 10 82 0 +35 67 85 -10 396 905 10 29 0 +36 65 85 -10 43 712 10 46 0 +37 65 82 10 530 703 0 0 101 +38 62 80 30 131 544 10 0 79 +39 60 80 10 36 800 10 0 43 +40 60 85 30 233 544 10 0 3 +41 58 75 20 207 664 10 0 78 +42 55 80 -16 33 624 10 65 0 +43 55 85 -10 549 718 10 39 0 +44 55 82 -9 62 491 10 67 0 +45 20 82 10 37 677 10 0 11 +46 18 80 10 435 662 10 0 36 +47 2 45 10 38 366 10 0 15 +48 42 5 10 636 904 10 0 66 +49 42 12 10 423 576 10 0 58 +50 72 35 -3 471 662 10 62 0 +51 55 20 -40 281 490 10 19 0 +52 25 30 3 109 360 10 0 23 +53 20 50 -8 284 585 10 72 0 +54 55 60 -10 568 753 10 33 0 +55 30 60 -28 421 896 10 86 0 +56 50 35 -16 404 829 10 75 0 +57 30 25 -20 347 566 10 12 0 +58 15 10 -10 380 902 10 49 0 +59 10 20 -15 42 466 10 99 0 +60 15 60 -10 613 894 10 20 0 +61 45 65 9 230 405 10 0 8 +62 65 35 3 29 587 10 0 50 +63 65 20 6 39 353 10 0 4 +64 45 30 17 20 497 10 0 95 +65 35 40 16 11 570 10 0 42 +66 41 37 -10 423 828 10 48 0 +67 64 42 9 112 543 10 0 44 +68 40 60 -10 441 902 10 14 0 +69 31 52 27 9 532 10 0 17 +70 35 69 -3 211 930 10 100 0 +71 65 55 -14 201 400 10 83 0 +72 63 65 8 27 382 10 0 53 +73 2 60 -19 255 436 10 88 0 +74 20 20 -20 427 913 10 9 0 +75 5 5 16 183 400 10 0 56 +76 60 12 31 162 493 10 0 92 +77 23 3 -9 360 900 10 98 0 +78 8 56 -20 195 654 10 41 0 +79 6 68 -30 258 565 10 38 0 +80 47 47 -13 426 942 10 91 0 +81 49 58 -20 369 460 10 31 0 +82 27 43 9 85 338 10 0 34 +83 37 31 14 19 326 10 0 71 +84 57 29 -10 304 605 10 21 0 +85 63 23 2 318 489 10 0 27 +86 21 24 28 332 485 10 0 55 +87 12 24 -20 365 472 10 16 0 +88 24 58 19 100 539 10 0 73 +89 67 5 -26 565 897 10 96 0 +90 37 47 -10 324 513 10 28 0 +91 49 42 13 651 906 10 0 80 +92 53 43 -31 14 669 10 76 0 +93 61 52 3 298 928 10 0 32 +94 57 48 -20 385 518 10 18 0 +95 56 37 -17 20 299 10 64 0 +96 55 54 26 538 705 10 0 89 +97 4 18 -40 546 667 10 22 0 +98 26 52 9 109 354 10 0 77 +99 26 35 15 170 565 10 0 59 +100 31 67 3 262 930 10 0 70 +101 65 82 -10 530 703 10 37 0 +102 35 5 -20 348 904 10 25 0 diff --git a/jsprit-instances/instances/lilim/lrc208.txt b/jsprit-instances/instances/lilim/lrc208.txt new file mode 100644 index 00000000..e279da5e --- /dev/null +++ b/jsprit-instances/instances/lilim/lrc208.txt @@ -0,0 +1,104 @@ +25 1000 1 +0 40 50 0 0 960 0 0 0 +1 25 85 20 388 911 0 0 101 +2 22 75 30 30 546 10 0 43 +3 22 85 10 353 708 10 0 35 +4 20 80 -3 425 913 10 52 0 +5 20 85 -10 40 630 10 81 0 +6 18 75 20 228 667 10 0 38 +7 15 75 20 161 558 10 0 37 +8 15 80 -14 229 624 10 71 0 +9 10 35 -35 213 648 10 97 0 +10 10 40 -9 404 753 10 82 0 +11 8 40 40 33 511 10 0 21 +12 8 45 20 46 519 10 0 59 +13 5 35 -16 395 911 10 75 0 +14 5 45 10 35 697 10 0 46 +15 2 40 -9 39 528 10 98 0 +16 0 40 20 94 535 10 0 25 +17 0 45 -5 394 909 10 53 0 +18 44 5 20 218 571 10 0 58 +19 42 10 40 85 542 10 0 86 +20 42 15 -20 391 802 10 31 0 +21 40 5 -40 45 517 10 11 0 +22 40 15 40 229 640 10 0 66 +23 38 5 -27 45 523 10 69 0 +24 38 15 -17 389 914 10 64 0 +25 35 5 -20 386 904 10 16 0 +26 95 30 30 389 788 10 0 27 +27 95 35 -30 57 600 10 26 0 +28 92 30 -10 55 575 10 32 0 +29 90 35 10 52 536 10 0 84 +30 88 30 10 90 521 10 0 62 +31 88 35 20 50 534 10 0 20 +32 87 30 10 425 898 10 0 28 +33 85 25 -6 51 602 10 90 0 +34 85 35 30 342 751 10 0 51 +35 67 85 -10 410 905 10 3 0 +36 65 85 40 43 617 10 0 96 +37 65 82 -20 410 823 10 7 0 +38 62 80 -20 114 561 10 6 0 +39 60 80 10 36 658 10 0 41 +40 60 85 30 191 586 10 0 54 +41 58 75 -10 201 670 10 39 0 +42 55 80 10 33 568 10 0 93 +43 55 85 -30 429 838 10 2 0 +44 55 82 -9 49 504 10 61 0 +45 20 82 -9 37 597 10 67 0 +46 18 80 -10 315 782 10 14 0 +47 2 45 10 38 606 10 0 48 +48 42 5 -10 396 904 10 47 0 +49 42 12 10 341 658 10 0 74 +50 72 35 -2 351 782 10 85 0 +51 55 20 -30 161 610 10 34 0 +52 25 30 3 25 516 10 0 4 +53 20 50 5 239 630 10 0 17 +54 55 60 -30 448 873 10 40 0 +55 30 60 -23 420 897 10 57 0 +56 50 35 19 390 843 10 0 80 +57 30 25 23 227 686 10 0 55 +58 15 10 -20 401 902 10 18 0 +59 10 20 -20 42 706 10 12 0 +60 15 60 17 401 923 10 0 68 +61 45 65 9 110 525 10 0 44 +62 65 35 -10 29 548 10 30 0 +63 65 20 6 39 593 10 0 89 +64 45 30 17 20 498 10 0 24 +65 35 40 16 11 530 10 0 83 +66 41 37 -40 404 847 10 22 0 +67 64 42 9 100 555 10 0 45 +68 40 60 -17 436 907 10 60 0 +69 31 52 27 9 510 10 0 23 +70 35 69 -5 330 930 10 73 0 +71 65 55 14 81 520 10 0 8 +72 63 65 8 27 622 10 0 94 +73 2 60 5 135 556 10 0 70 +74 20 20 -10 430 913 10 49 0 +75 5 5 16 63 520 10 0 13 +76 60 12 31 125 530 10 0 91 +77 23 3 -30 390 900 10 79 0 +78 8 56 27 190 659 10 0 100 +79 6 68 30 215 608 10 0 77 +80 47 47 -19 444 942 10 56 0 +81 49 58 10 249 580 10 0 5 +82 27 43 9 14 506 10 0 10 +83 37 31 -16 19 566 10 65 0 +84 57 29 -10 259 650 10 29 0 +85 63 23 2 198 609 10 0 50 +86 21 24 -40 212 605 10 19 0 +87 12 24 13 272 565 0 0 102 +88 24 58 19 90 549 10 0 99 +89 67 5 -6 325 897 10 63 0 +90 37 47 6 204 633 10 0 33 +91 49 42 -31 442 937 10 76 0 +92 53 43 14 14 581 10 0 95 +93 61 52 -10 373 928 10 42 0 +94 57 48 -8 265 638 10 72 0 +95 56 37 -14 20 539 10 92 0 +96 55 54 -40 418 825 10 36 0 +97 4 18 35 426 787 10 0 9 +98 26 52 9 14 499 10 0 15 +99 26 35 -19 149 586 10 88 0 +100 31 67 -27 356 930 10 78 0 +101 25 85 -20 388 911 10 1 0 +102 12 24 -13 272 565 10 87 0 diff --git a/jsprit-instances/instances/liushen/C1.txt b/jsprit-instances/instances/liushen/C1.txt new file mode 100644 index 00000000..75adb65b --- /dev/null +++ b/jsprit-instances/instances/liushen/C1.txt @@ -0,0 +1,4 @@ +Vehicle;Capacity;Cost_a;Cost_b;Cost_c +A;100;300;60;30 +B;200;800;160;80 +C;300;1350;270;135 \ No newline at end of file diff --git a/jsprit-instances/instances/liushen/R1.txt b/jsprit-instances/instances/liushen/R1.txt new file mode 100644 index 00000000..8bb389b4 --- /dev/null +++ b/jsprit-instances/instances/liushen/R1.txt @@ -0,0 +1,6 @@ +Vehicle;Capacity;Cost_R1a;Cost_R1b;Cost_R1c +A;30;50;10;5 +B;50;80;16;8 +C;80;140;28;14 +D;120;250;50;25 +E;200;500;100;50 \ No newline at end of file diff --git a/jsprit-instances/instances/solomon/C101.txt b/jsprit-instances/instances/solomon/C101.txt new file mode 100644 index 00000000..28cdccc6 --- /dev/null +++ b/jsprit-instances/instances/solomon/C101.txt @@ -0,0 +1,110 @@ +C101 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 912 967 90 + 2 45 70 30 825 870 90 + 3 42 66 10 65 146 90 + 4 42 68 10 727 782 90 + 5 42 65 10 15 67 90 + 6 40 69 20 621 702 90 + 7 40 66 20 170 225 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 357 410 90 + 11 35 69 10 448 505 90 + 12 25 85 20 652 721 90 + 13 22 75 30 30 92 90 + 14 22 85 10 567 620 90 + 15 20 80 40 384 429 90 + 16 20 85 40 475 528 90 + 17 18 75 20 99 148 90 + 18 15 75 20 179 254 90 + 19 15 80 10 278 345 90 + 20 30 50 10 10 73 90 + 21 30 52 20 914 965 90 + 22 28 52 20 812 883 90 + 23 28 55 10 732 777 90 + 24 25 50 10 65 144 90 + 25 25 52 40 169 224 90 + 26 25 55 10 622 701 90 + 27 23 52 10 261 316 90 + 28 23 55 20 546 593 90 + 29 20 50 10 358 405 90 + 30 20 55 10 449 504 90 + 31 10 35 20 200 237 90 + 32 10 40 30 31 100 90 + 33 8 40 40 87 158 90 + 34 8 45 20 751 816 90 + 35 5 35 10 283 344 90 + 36 5 45 10 665 716 90 + 37 2 40 20 383 434 90 + 38 0 40 30 479 522 90 + 39 0 45 20 567 624 90 + 40 35 30 10 264 321 90 + 41 35 32 10 166 235 90 + 42 33 32 20 68 149 90 + 43 33 35 10 16 80 90 + 44 32 30 10 359 412 90 + 45 30 30 10 541 600 90 + 46 30 32 30 448 509 90 + 47 30 35 10 1054 1127 90 + 48 28 30 10 632 693 90 + 49 28 35 10 1001 1066 90 + 50 26 32 10 815 880 90 + 51 25 30 10 725 786 90 + 52 25 35 10 912 969 90 + 53 44 5 20 286 347 90 + 54 42 10 40 186 257 90 + 55 42 15 10 95 158 90 + 56 40 5 30 385 436 90 + 57 40 15 40 35 87 90 + 58 38 5 30 471 534 90 + 59 38 15 10 651 740 90 + 60 35 5 20 562 629 90 + 61 50 30 10 531 610 90 + 62 50 35 20 262 317 90 + 63 50 40 50 171 218 90 + 64 48 30 10 632 693 90 + 65 48 40 10 76 129 90 + 66 47 35 10 826 875 90 + 67 47 40 10 12 77 90 + 68 45 30 10 734 777 90 + 69 45 35 10 916 969 90 + 70 95 30 30 387 456 90 + 71 95 35 20 293 360 90 + 72 53 30 10 450 505 90 + 73 92 30 10 478 551 90 + 74 53 35 50 353 412 90 + 75 45 65 20 997 1068 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 109 170 90 + 79 87 30 10 668 731 90 + 80 85 25 10 769 820 90 + 81 85 35 30 47 124 90 + 82 75 55 20 369 420 90 + 83 72 55 10 265 338 90 + 84 70 58 20 458 523 90 + 85 68 60 30 555 612 90 + 86 66 55 10 173 238 90 + 87 65 55 20 85 144 90 + 88 65 60 30 645 708 90 + 89 63 58 10 737 802 90 + 90 60 55 10 20 84 90 + 91 60 60 10 836 889 90 + 92 67 85 20 368 441 90 + 93 65 85 40 475 518 90 + 94 65 82 10 285 336 90 + 95 62 80 30 196 239 90 + 96 60 80 10 95 156 90 + 97 60 85 30 561 622 90 + 98 58 75 20 30 84 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-instances/instances/solomon/C102.txt b/jsprit-instances/instances/solomon/C102.txt new file mode 100644 index 00000000..88996ce7 --- /dev/null +++ b/jsprit-instances/instances/solomon/C102.txt @@ -0,0 +1,110 @@ +C102 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 0 1127 90 + 2 45 70 30 0 1125 90 + 3 42 66 10 0 1129 90 + 4 42 68 10 727 782 90 + 5 42 65 10 0 1130 90 + 6 40 69 20 621 702 90 + 7 40 66 20 0 1130 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 357 410 90 + 11 35 69 10 448 505 90 + 12 25 85 20 0 1107 90 + 13 22 75 30 30 92 90 + 14 22 85 10 567 620 90 + 15 20 80 40 384 429 90 + 16 20 85 40 475 528 90 + 17 18 75 20 99 148 90 + 18 15 75 20 179 254 90 + 19 15 80 10 278 345 90 + 20 30 50 10 10 73 90 + 21 30 52 20 0 1135 90 + 22 28 52 20 812 883 90 + 23 28 55 10 732 777 90 + 24 25 50 10 65 144 90 + 25 25 52 40 169 224 90 + 26 25 55 10 0 1130 90 + 27 23 52 10 261 316 90 + 28 23 55 20 546 593 90 + 29 20 50 10 358 405 90 + 30 20 55 10 449 504 90 + 31 10 35 20 0 1112 90 + 32 10 40 30 31 100 90 + 33 8 40 40 87 158 90 + 34 8 45 20 0 1113 90 + 35 5 35 10 283 344 90 + 36 5 45 10 665 716 90 + 37 2 40 20 0 1106 90 + 38 0 40 30 479 522 90 + 39 0 45 20 567 624 90 + 40 35 30 10 264 321 90 + 41 35 32 10 166 235 90 + 42 33 32 20 68 149 90 + 43 33 35 10 16 80 90 + 44 32 30 10 359 412 90 + 45 30 30 10 541 600 90 + 46 30 32 30 448 509 90 + 47 30 35 10 1054 1127 90 + 48 28 30 10 0 1122 90 + 49 28 35 10 1001 1066 90 + 50 26 32 10 0 1123 90 + 51 25 30 10 725 786 90 + 52 25 35 10 0 1124 90 + 53 44 5 20 286 347 90 + 54 42 10 40 186 257 90 + 55 42 15 10 95 158 90 + 56 40 5 30 385 436 90 + 57 40 15 40 35 87 90 + 58 38 5 30 471 534 90 + 59 38 15 10 0 1110 90 + 60 35 5 20 562 629 90 + 61 50 30 10 531 610 90 + 62 50 35 20 262 317 90 + 63 50 40 50 171 218 90 + 64 48 30 10 632 693 90 + 65 48 40 10 76 129 90 + 66 47 35 10 826 875 90 + 67 47 40 10 12 77 90 + 68 45 30 10 734 777 90 + 69 45 35 10 916 969 90 + 70 95 30 30 387 456 90 + 71 95 35 20 293 360 90 + 72 53 30 10 0 1122 90 + 73 92 30 10 478 551 90 + 74 53 35 50 353 412 90 + 75 45 65 20 0 1130 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 109 170 90 + 79 87 30 10 668 731 90 + 80 85 25 10 769 820 90 + 81 85 35 30 47 124 90 + 82 75 55 20 0 1110 90 + 83 72 55 10 0 1113 90 + 84 70 58 20 458 523 90 + 85 68 60 30 0 1116 90 + 86 66 55 10 173 238 90 + 87 65 55 20 85 144 90 + 88 65 60 30 645 708 90 + 89 63 58 10 737 802 90 + 90 60 55 10 20 84 90 + 91 60 60 10 0 1123 90 + 92 67 85 20 368 441 90 + 93 65 85 40 475 518 90 + 94 65 82 10 0 1105 90 + 95 62 80 30 0 1108 90 + 96 60 80 10 0 1109 90 + 97 60 85 30 561 622 90 + 98 58 75 20 0 1115 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-instances/instances/solomon/C103.txt b/jsprit-instances/instances/solomon/C103.txt new file mode 100644 index 00000000..e6642cec --- /dev/null +++ b/jsprit-instances/instances/solomon/C103.txt @@ -0,0 +1,110 @@ +C103 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 0 1127 90 + 2 45 70 30 0 1125 90 + 3 42 66 10 0 1129 90 + 4 42 68 10 727 782 90 + 5 42 65 10 0 1130 90 + 6 40 69 20 621 702 90 + 7 40 66 20 0 1130 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 357 410 90 + 11 35 69 10 448 505 90 + 12 25 85 20 0 1107 90 + 13 22 75 30 30 92 90 + 14 22 85 10 0 1106 90 + 15 20 80 40 384 429 90 + 16 20 85 40 0 1105 90 + 17 18 75 20 99 148 90 + 18 15 75 20 0 1110 90 + 19 15 80 10 0 1106 90 + 20 30 50 10 0 1136 90 + 21 30 52 20 0 1135 90 + 22 28 52 20 812 883 90 + 23 28 55 10 732 777 90 + 24 25 50 10 0 1131 90 + 25 25 52 40 169 224 90 + 26 25 55 10 0 1130 90 + 27 23 52 10 261 316 90 + 28 23 55 20 0 1128 90 + 29 20 50 10 0 1126 90 + 30 20 55 10 449 504 90 + 31 10 35 20 0 1112 90 + 32 10 40 30 0 1114 90 + 33 8 40 40 87 158 90 + 34 8 45 20 0 1113 90 + 35 5 35 10 283 344 90 + 36 5 45 10 665 716 90 + 37 2 40 20 0 1106 90 + 38 0 40 30 479 522 90 + 39 0 45 20 567 624 90 + 40 35 30 10 264 321 90 + 41 35 32 10 166 235 90 + 42 33 32 20 68 149 90 + 43 33 35 10 0 1129 90 + 44 32 30 10 359 412 90 + 45 30 30 10 541 600 90 + 46 30 32 30 0 1125 90 + 47 30 35 10 0 1127 90 + 48 28 30 10 0 1122 90 + 49 28 35 10 1001 1066 90 + 50 26 32 10 0 1123 90 + 51 25 30 10 0 1121 90 + 52 25 35 10 0 1124 90 + 53 44 5 20 286 347 90 + 54 42 10 40 0 1105 90 + 55 42 15 10 95 158 90 + 56 40 5 30 385 436 90 + 57 40 15 40 0 1111 90 + 58 38 5 30 471 534 90 + 59 38 15 10 0 1110 90 + 60 35 5 20 0 1100 90 + 61 50 30 10 0 1123 90 + 62 50 35 20 262 317 90 + 63 50 40 50 0 1131 90 + 64 48 30 10 632 693 90 + 65 48 40 10 76 129 90 + 66 47 35 10 826 875 90 + 67 47 40 10 12 77 90 + 68 45 30 10 734 777 90 + 69 45 35 10 916 969 90 + 70 95 30 30 387 456 90 + 71 95 35 20 0 1088 90 + 72 53 30 10 0 1122 90 + 73 92 30 10 0 1090 90 + 74 53 35 50 353 412 90 + 75 45 65 20 0 1130 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 109 170 90 + 79 87 30 10 668 731 90 + 80 85 25 10 769 820 90 + 81 85 35 30 0 1098 90 + 82 75 55 20 0 1110 90 + 83 72 55 10 0 1113 90 + 84 70 58 20 458 523 90 + 85 68 60 30 0 1116 90 + 86 66 55 10 0 1119 90 + 87 65 55 20 85 144 90 + 88 65 60 30 645 708 90 + 89 63 58 10 0 1121 90 + 90 60 55 10 0 1125 90 + 91 60 60 10 0 1123 90 + 92 67 85 20 368 441 90 + 93 65 85 40 475 518 90 + 94 65 82 10 0 1105 90 + 95 62 80 30 0 1108 90 + 96 60 80 10 0 1109 90 + 97 60 85 30 0 1105 90 + 98 58 75 20 0 1115 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-instances/instances/solomon/C104.txt b/jsprit-instances/instances/solomon/C104.txt new file mode 100644 index 00000000..fe8c3a10 --- /dev/null +++ b/jsprit-instances/instances/solomon/C104.txt @@ -0,0 +1,110 @@ +C104 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 0 1127 90 + 2 45 70 30 0 1125 90 + 3 42 66 10 0 1129 90 + 4 42 68 10 727 782 90 + 5 42 65 10 0 1130 90 + 6 40 69 20 0 1127 90 + 7 40 66 20 0 1130 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 0 1129 90 + 11 35 69 10 448 505 90 + 12 25 85 20 0 1107 90 + 13 22 75 30 30 92 90 + 14 22 85 10 0 1106 90 + 15 20 80 40 384 429 90 + 16 20 85 40 0 1105 90 + 17 18 75 20 0 1112 90 + 18 15 75 20 0 1110 90 + 19 15 80 10 0 1106 90 + 20 30 50 10 0 1136 90 + 21 30 52 20 0 1135 90 + 22 28 52 20 0 1133 90 + 23 28 55 10 732 777 90 + 24 25 50 10 0 1131 90 + 25 25 52 40 169 224 90 + 26 25 55 10 0 1130 90 + 27 23 52 10 0 1128 90 + 28 23 55 20 0 1128 90 + 29 20 50 10 0 1126 90 + 30 20 55 10 0 1125 90 + 31 10 35 20 0 1112 90 + 32 10 40 30 0 1114 90 + 33 8 40 40 0 1112 90 + 34 8 45 20 0 1113 90 + 35 5 35 10 0 1107 90 + 36 5 45 10 0 1110 90 + 37 2 40 20 0 1106 90 + 38 0 40 30 479 522 90 + 39 0 45 20 0 1105 90 + 40 35 30 10 0 1125 90 + 41 35 32 10 0 1127 90 + 42 33 32 20 0 1126 90 + 43 33 35 10 0 1129 90 + 44 32 30 10 359 412 90 + 45 30 30 10 0 1123 90 + 46 30 32 30 0 1125 90 + 47 30 35 10 0 1127 90 + 48 28 30 10 0 1122 90 + 49 28 35 10 0 1126 90 + 50 26 32 10 0 1123 90 + 51 25 30 10 0 1121 90 + 52 25 35 10 0 1124 90 + 53 44 5 20 286 347 90 + 54 42 10 40 0 1105 90 + 55 42 15 10 95 158 90 + 56 40 5 30 0 1101 90 + 57 40 15 40 0 1111 90 + 58 38 5 30 471 534 90 + 59 38 15 10 0 1110 90 + 60 35 5 20 0 1100 90 + 61 50 30 10 0 1123 90 + 62 50 35 20 262 317 90 + 63 50 40 50 0 1131 90 + 64 48 30 10 0 1124 90 + 65 48 40 10 0 1133 90 + 66 47 35 10 0 1129 90 + 67 47 40 10 12 77 90 + 68 45 30 10 0 1125 90 + 69 45 35 10 916 969 90 + 70 95 30 30 0 1087 90 + 71 95 35 20 0 1088 90 + 72 53 30 10 0 1122 90 + 73 92 30 10 0 1090 90 + 74 53 35 50 353 412 90 + 75 45 65 20 0 1130 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 0 1095 90 + 79 87 30 10 668 731 90 + 80 85 25 10 0 1094 90 + 81 85 35 30 0 1098 90 + 82 75 55 20 0 1110 90 + 83 72 55 10 0 1113 90 + 84 70 58 20 458 523 90 + 85 68 60 30 0 1116 90 + 86 66 55 10 0 1119 90 + 87 65 55 20 85 144 90 + 88 65 60 30 0 1119 90 + 89 63 58 10 0 1121 90 + 90 60 55 10 0 1125 90 + 91 60 60 10 0 1123 90 + 92 67 85 20 368 441 90 + 93 65 85 40 0 1102 90 + 94 65 82 10 0 1105 90 + 95 62 80 30 0 1108 90 + 96 60 80 10 0 1109 90 + 97 60 85 30 0 1105 90 + 98 58 75 20 0 1115 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-instances/instances/solomon/C105.txt b/jsprit-instances/instances/solomon/C105.txt new file mode 100644 index 00000000..9a2d6b9b --- /dev/null +++ b/jsprit-instances/instances/solomon/C105.txt @@ -0,0 +1,110 @@ +C105 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 885 994 90 + 2 45 70 30 802 893 90 + 3 42 66 10 25 186 90 + 4 42 68 10 699 810 90 + 5 42 65 10 15 120 90 + 6 40 69 20 580 743 90 + 7 40 66 20 142 253 90 + 8 38 68 20 220 359 90 + 9 38 70 10 499 640 90 + 10 35 66 10 331 436 90 + 11 35 69 10 420 533 90 + 12 25 85 20 617 756 90 + 13 22 75 30 30 155 90 + 14 22 85 10 541 646 90 + 15 20 80 40 362 451 90 + 16 20 85 40 448 555 90 + 17 18 75 20 75 172 90 + 18 15 75 20 142 291 90 + 19 15 80 10 244 379 90 + 20 30 50 10 10 137 90 + 21 30 52 20 888 991 90 + 22 28 52 20 776 919 90 + 23 28 55 10 709 800 90 + 24 25 50 10 25 184 90 + 25 25 52 40 142 251 90 + 26 25 55 10 582 741 90 + 27 23 52 10 234 343 90 + 28 23 55 20 523 616 90 + 29 20 50 10 335 428 90 + 30 20 55 10 422 531 90 + 31 10 35 20 181 256 90 + 32 10 40 30 31 170 90 + 33 8 40 40 52 193 90 + 34 8 45 20 719 848 90 + 35 5 35 10 252 375 90 + 36 5 45 10 639 742 90 + 37 2 40 20 357 460 90 + 38 0 40 30 457 544 90 + 39 0 45 20 538 653 90 + 40 35 30 10 236 349 90 + 41 35 32 10 132 269 90 + 42 33 32 20 27 190 90 + 43 33 35 10 16 144 90 + 44 32 30 10 332 439 90 + 45 30 30 10 512 629 90 + 46 30 32 30 417 540 90 + 47 30 35 10 982 1127 90 + 48 28 30 10 601 724 90 + 49 28 35 10 969 1098 90 + 50 26 32 10 783 912 90 + 51 25 30 10 695 816 90 + 52 25 35 10 883 998 90 + 53 44 5 20 255 378 90 + 54 42 10 40 150 293 90 + 55 42 15 10 63 190 90 + 56 40 5 30 359 462 90 + 57 40 15 40 35 140 90 + 58 38 5 30 439 566 90 + 59 38 15 10 607 784 90 + 60 35 5 20 529 662 90 + 61 50 30 10 491 650 90 + 62 50 35 20 235 344 90 + 63 50 40 50 147 242 90 + 64 48 30 10 601 724 90 + 65 48 40 10 50 155 90 + 66 47 35 10 802 899 90 + 67 47 40 10 12 143 90 + 68 45 30 10 712 799 90 + 69 45 35 10 889 996 90 + 70 95 30 30 353 490 90 + 71 95 35 20 260 393 90 + 72 53 30 10 422 533 90 + 73 92 30 10 442 587 90 + 74 53 35 50 323 442 90 + 75 45 65 20 962 1103 90 + 76 90 35 10 175 288 90 + 77 88 30 10 539 678 90 + 78 88 35 20 78 201 90 + 79 87 30 10 636 763 90 + 80 85 25 10 744 845 90 + 81 85 35 30 47 201 90 + 82 75 55 20 344 445 90 + 83 72 55 10 228 375 90 + 84 70 58 20 425 556 90 + 85 68 60 30 527 640 90 + 86 66 55 10 141 270 90 + 87 65 55 20 56 173 90 + 88 65 60 30 614 739 90 + 89 63 58 10 705 834 90 + 90 60 55 10 20 148 90 + 91 60 60 10 809 916 90 + 92 67 85 20 331 478 90 + 93 65 85 40 453 540 90 + 94 65 82 10 260 361 90 + 95 62 80 30 174 261 90 + 96 60 80 10 64 187 90 + 97 60 85 30 531 652 90 + 98 58 75 20 30 139 90 + 99 55 80 10 705 858 90 + 100 55 85 20 608 765 90 diff --git a/jsprit-instances/instances/solomon/C106.txt b/jsprit-instances/instances/solomon/C106.txt new file mode 100644 index 00000000..ee625d11 --- /dev/null +++ b/jsprit-instances/instances/solomon/C106.txt @@ -0,0 +1,110 @@ +C106 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 890 989 90 + 2 45 70 30 816 879 90 + 3 42 66 10 55 156 90 + 4 42 68 10 703 806 90 + 5 42 65 10 15 60 90 + 6 40 69 20 559 764 90 + 7 40 66 20 172 223 90 + 8 38 68 20 250 329 90 + 9 38 70 10 489 650 90 + 10 35 66 10 361 406 90 + 11 35 69 10 450 503 90 + 12 25 85 20 647 726 90 + 13 22 75 30 30 95 90 + 14 22 85 10 571 616 90 + 15 20 80 40 392 421 90 + 16 20 85 40 478 525 90 + 17 18 75 20 105 142 90 + 18 15 75 20 172 261 90 + 19 15 80 10 274 349 90 + 20 30 50 10 10 77 90 + 21 30 52 20 918 961 90 + 22 28 52 20 806 889 90 + 23 28 55 10 739 770 90 + 24 25 50 10 55 154 90 + 25 25 52 40 172 221 90 + 26 25 55 10 612 711 90 + 27 23 52 10 264 313 90 + 28 23 55 20 553 586 90 + 29 20 50 10 365 398 90 + 30 20 55 10 452 501 90 + 31 10 35 20 204 233 90 + 32 10 40 30 31 189 90 + 33 8 40 40 42 203 90 + 34 8 45 20 715 852 90 + 35 5 35 10 251 376 90 + 36 5 45 10 648 733 90 + 37 2 40 20 365 452 90 + 38 0 40 30 474 527 90 + 39 0 45 20 541 650 90 + 40 35 30 10 240 345 90 + 41 35 32 10 123 278 90 + 42 33 32 20 19 225 90 + 43 33 35 10 16 153 90 + 44 32 30 10 338 433 90 + 45 30 30 10 513 628 90 + 46 30 32 30 415 542 90 + 47 30 35 10 872 1127 90 + 48 28 30 10 599 726 90 + 49 28 35 10 917 1126 90 + 50 26 32 10 779 916 90 + 51 25 30 10 695 816 90 + 52 25 35 10 857 1024 90 + 53 44 5 20 221 412 90 + 54 42 10 40 96 347 90 + 55 42 15 10 35 233 90 + 56 40 5 30 347 474 90 + 57 40 15 40 35 172 90 + 58 38 5 30 403 602 90 + 59 38 15 10 521 870 90 + 60 35 5 20 487 704 90 + 61 50 30 10 422 719 90 + 62 50 35 20 217 362 90 + 63 50 40 50 142 247 90 + 64 48 30 10 567 758 90 + 65 48 40 10 34 171 90 + 66 47 35 10 794 907 90 + 67 47 40 10 12 226 90 + 68 45 30 10 716 795 90 + 69 45 35 10 873 1012 90 + 70 95 30 30 266 577 90 + 71 95 35 20 181 472 90 + 72 53 30 10 402 553 90 + 73 92 30 10 345 684 90 + 74 53 35 50 294 471 90 + 75 45 65 20 951 1114 90 + 76 90 35 10 153 310 90 + 77 88 30 10 450 767 90 + 78 88 35 20 50 237 90 + 79 87 30 10 567 832 90 + 80 85 25 10 713 876 90 + 81 85 35 30 47 331 90 + 82 75 55 20 311 478 90 + 83 72 55 10 127 476 90 + 84 70 58 20 349 632 90 + 85 68 60 30 476 691 90 + 86 66 55 10 67 344 90 + 87 65 55 20 25 256 90 + 88 65 60 30 546 807 90 + 89 63 58 10 630 909 90 + 90 60 55 10 20 293 90 + 91 60 60 10 769 956 90 + 92 67 85 20 229 580 90 + 93 65 85 40 442 551 90 + 94 65 82 10 227 394 90 + 95 62 80 30 163 272 90 + 96 60 80 10 36 291 90 + 97 60 85 30 469 714 90 + 98 58 75 20 30 227 90 + 99 55 80 10 595 968 90 + 100 55 85 20 493 880 90 diff --git a/jsprit-instances/instances/solomon/C107.txt b/jsprit-instances/instances/solomon/C107.txt new file mode 100644 index 00000000..b7e1ba90 --- /dev/null +++ b/jsprit-instances/instances/solomon/C107.txt @@ -0,0 +1,110 @@ +C107 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 850 1030 90 + 2 45 70 30 758 938 90 + 3 42 66 10 16 196 90 + 4 42 68 10 665 845 90 + 5 42 65 10 15 195 90 + 6 40 69 20 572 752 90 + 7 40 66 20 108 288 90 + 8 38 68 20 200 380 90 + 9 38 70 10 480 660 90 + 10 35 66 10 294 474 90 + 11 35 69 10 387 567 90 + 12 25 85 20 597 777 90 + 13 22 75 30 30 210 90 + 14 22 85 10 504 684 90 + 15 20 80 40 317 497 90 + 16 20 85 40 412 592 90 + 17 18 75 20 34 214 90 + 18 15 75 20 127 307 90 + 19 15 80 10 222 402 90 + 20 30 50 10 10 190 90 + 21 30 52 20 850 1030 90 + 22 28 52 20 758 938 90 + 23 28 55 10 665 845 90 + 24 25 50 10 15 195 90 + 25 25 52 40 107 287 90 + 26 25 55 10 572 752 90 + 27 23 52 10 199 379 90 + 28 23 55 20 480 660 90 + 29 20 50 10 292 472 90 + 30 20 55 10 387 567 90 + 31 10 35 20 129 309 90 + 32 10 40 30 31 211 90 + 33 8 40 40 33 213 90 + 34 8 45 20 694 874 90 + 35 5 35 10 224 404 90 + 36 5 45 10 601 781 90 + 37 2 40 20 319 499 90 + 38 0 40 30 411 591 90 + 39 0 45 20 506 686 90 + 40 35 30 10 203 383 90 + 41 35 32 10 111 291 90 + 42 33 32 20 19 199 90 + 43 33 35 10 16 196 90 + 44 32 30 10 296 476 90 + 45 30 30 10 481 661 90 + 46 30 32 30 389 569 90 + 47 30 35 10 947 1127 90 + 48 28 30 10 573 753 90 + 49 28 35 10 944 1124 90 + 50 26 32 10 758 938 90 + 51 25 30 10 666 846 90 + 52 25 35 10 851 1031 90 + 53 44 5 20 227 407 90 + 54 42 10 40 132 312 90 + 55 42 15 10 37 217 90 + 56 40 5 30 321 501 90 + 57 40 15 40 35 215 90 + 58 38 5 30 413 593 90 + 59 38 15 10 606 786 90 + 60 35 5 20 506 686 90 + 61 50 30 10 481 661 90 + 62 50 35 20 200 380 90 + 63 50 40 50 105 285 90 + 64 48 30 10 573 753 90 + 65 48 40 10 13 193 90 + 66 47 35 10 761 941 90 + 67 47 40 10 12 192 90 + 68 45 30 10 666 846 90 + 69 45 35 10 853 1033 90 + 70 95 30 30 332 512 90 + 71 95 35 20 237 417 90 + 72 53 30 10 388 568 90 + 73 92 30 10 425 605 90 + 74 53 35 50 293 473 90 + 75 45 65 20 943 1123 90 + 76 90 35 10 142 322 90 + 77 88 30 10 519 699 90 + 78 88 35 20 50 230 90 + 79 87 30 10 610 790 90 + 80 85 25 10 705 885 90 + 81 85 35 30 47 227 90 + 82 75 55 20 305 485 90 + 83 72 55 10 212 392 90 + 84 70 58 20 401 581 90 + 85 68 60 30 494 674 90 + 86 66 55 10 116 296 90 + 87 65 55 20 25 205 90 + 88 65 60 30 587 767 90 + 89 63 58 10 680 860 90 + 90 60 55 10 20 200 90 + 91 60 60 10 773 953 90 + 92 67 85 20 315 495 90 + 93 65 85 40 407 587 90 + 94 65 82 10 221 401 90 + 95 62 80 30 128 308 90 + 96 60 80 10 36 216 90 + 97 60 85 30 502 682 90 + 98 58 75 20 30 210 90 + 99 55 80 10 692 872 90 + 100 55 85 20 597 777 90 diff --git a/jsprit-instances/instances/solomon/C108.txt b/jsprit-instances/instances/solomon/C108.txt new file mode 100644 index 00000000..085c8006 --- /dev/null +++ b/jsprit-instances/instances/solomon/C108.txt @@ -0,0 +1,110 @@ +C108 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 830 1049 90 + 2 45 70 30 756 939 90 + 3 42 66 10 16 336 90 + 4 42 68 10 643 866 90 + 5 42 65 10 15 226 90 + 6 40 69 20 499 824 90 + 7 40 66 20 87 308 90 + 8 38 68 20 150 429 90 + 9 38 70 10 429 710 90 + 10 35 66 10 279 488 90 + 11 35 69 10 363 590 90 + 12 25 85 20 547 826 90 + 13 22 75 30 30 280 90 + 14 22 85 10 489 698 90 + 15 20 80 40 318 495 90 + 16 20 85 40 394 609 90 + 17 18 75 20 33 226 90 + 18 15 75 20 68 365 90 + 19 15 80 10 176 447 90 + 20 30 50 10 10 265 90 + 21 30 52 20 836 1043 90 + 22 28 52 20 704 991 90 + 23 28 55 10 664 845 90 + 24 25 50 10 15 333 90 + 25 25 52 40 88 305 90 + 26 25 55 10 502 821 90 + 27 23 52 10 179 398 90 + 28 23 55 20 476 663 90 + 29 20 50 10 288 475 90 + 30 20 55 10 368 585 90 + 31 10 35 20 144 293 90 + 32 10 40 30 31 309 90 + 33 8 40 40 33 313 90 + 34 8 45 20 655 912 90 + 35 5 35 10 191 436 90 + 36 5 45 10 588 793 90 + 37 2 40 20 305 512 90 + 38 0 40 30 414 587 90 + 39 0 45 20 481 710 90 + 40 35 30 10 180 405 90 + 41 35 32 10 63 338 90 + 42 33 32 20 19 345 90 + 43 33 35 10 16 273 90 + 44 32 30 10 278 493 90 + 45 30 30 10 453 688 90 + 46 30 32 30 355 602 90 + 47 30 35 10 837 1127 90 + 48 28 30 10 539 786 90 + 49 28 35 10 867 1126 90 + 50 26 32 10 719 976 90 + 51 25 30 10 635 876 90 + 52 25 35 10 825 1056 90 + 53 44 5 20 193 440 90 + 54 42 10 40 78 365 90 + 55 42 15 10 35 287 90 + 56 40 5 30 308 513 90 + 57 40 15 40 35 246 90 + 58 38 5 30 376 629 90 + 59 38 15 10 519 872 90 + 60 35 5 20 463 728 90 + 61 50 30 10 412 729 90 + 62 50 35 20 181 398 90 + 63 50 40 50 100 289 90 + 64 48 30 10 539 786 90 + 65 48 40 10 12 223 90 + 66 47 35 10 753 948 90 + 67 47 40 10 12 275 90 + 68 45 30 10 669 842 90 + 69 45 35 10 836 1049 90 + 70 95 30 30 284 559 90 + 71 95 35 20 194 459 90 + 72 53 30 10 367 588 90 + 73 92 30 10 370 659 90 + 74 53 35 50 263 502 90 + 75 45 65 20 847 1130 90 + 76 90 35 10 119 344 90 + 77 88 30 10 469 748 90 + 78 88 35 20 50 295 90 + 79 87 30 10 573 826 90 + 80 85 25 10 694 895 90 + 81 85 35 30 47 356 90 + 82 75 55 20 293 496 90 + 83 72 55 10 154 449 90 + 84 70 58 20 360 621 90 + 85 68 60 30 470 697 90 + 86 66 55 10 76 335 90 + 87 65 55 20 25 260 90 + 88 65 60 30 551 802 90 + 89 63 58 10 640 899 90 + 90 60 55 10 20 276 90 + 91 60 60 10 756 969 90 + 92 67 85 20 257 552 90 + 93 65 85 40 409 584 90 + 94 65 82 10 209 412 90 + 95 62 80 30 130 305 90 + 96 60 80 10 36 283 90 + 97 60 85 30 470 713 90 + 98 58 75 20 30 248 90 + 99 55 80 10 628 935 90 + 100 55 85 20 530 843 90 diff --git a/jsprit-instances/instances/solomon/C109.txt b/jsprit-instances/instances/solomon/C109.txt new file mode 100644 index 00000000..b33eb87b --- /dev/null +++ b/jsprit-instances/instances/solomon/C109.txt @@ -0,0 +1,110 @@ +C109 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 760 1120 90 + 2 45 70 30 668 1028 90 + 3 42 66 10 16 376 90 + 4 42 68 10 575 935 90 + 5 42 65 10 15 375 90 + 6 40 69 20 482 842 90 + 7 40 66 20 18 378 90 + 8 38 68 20 110 470 90 + 9 38 70 10 390 750 90 + 10 35 66 10 204 564 90 + 11 35 69 10 297 657 90 + 12 25 85 20 507 867 90 + 13 22 75 30 30 390 90 + 14 22 85 10 414 774 90 + 15 20 80 40 227 587 90 + 16 20 85 40 322 682 90 + 17 18 75 20 33 393 90 + 18 15 75 20 37 397 90 + 19 15 80 10 132 492 90 + 20 30 50 10 10 370 90 + 21 30 52 20 760 1120 90 + 22 28 52 20 668 1028 90 + 23 28 55 10 575 935 90 + 24 25 50 10 15 375 90 + 25 25 52 40 17 377 90 + 26 25 55 10 482 842 90 + 27 23 52 10 109 469 90 + 28 23 55 20 390 750 90 + 29 20 50 10 202 562 90 + 30 20 55 10 297 657 90 + 31 10 35 20 39 399 90 + 32 10 40 30 31 391 90 + 33 8 40 40 33 393 90 + 34 8 45 20 604 964 90 + 35 5 35 10 134 494 90 + 36 5 45 10 511 871 90 + 37 2 40 20 229 589 90 + 38 0 40 30 321 681 90 + 39 0 45 20 416 776 90 + 40 35 30 10 113 473 90 + 41 35 32 10 21 381 90 + 42 33 32 20 19 379 90 + 43 33 35 10 16 376 90 + 44 32 30 10 206 566 90 + 45 30 30 10 391 751 90 + 46 30 32 30 299 659 90 + 47 30 35 10 767 1127 90 + 48 28 30 10 483 843 90 + 49 28 35 10 766 1126 90 + 50 26 32 10 668 1028 90 + 51 25 30 10 576 936 90 + 52 25 35 10 761 1121 90 + 53 44 5 20 137 497 90 + 54 42 10 40 42 402 90 + 55 42 15 10 35 395 90 + 56 40 5 30 231 591 90 + 57 40 15 40 35 395 90 + 58 38 5 30 323 683 90 + 59 38 15 10 516 876 90 + 60 35 5 20 416 776 90 + 61 50 30 10 391 751 90 + 62 50 35 20 110 470 90 + 63 50 40 50 15 375 90 + 64 48 30 10 483 843 90 + 65 48 40 10 12 372 90 + 66 47 35 10 671 1031 90 + 67 47 40 10 12 372 90 + 68 45 30 10 576 936 90 + 69 45 35 10 763 1123 90 + 70 95 30 30 242 602 90 + 71 95 35 20 147 507 90 + 72 53 30 10 298 658 90 + 73 92 30 10 335 695 90 + 74 53 35 50 203 563 90 + 75 45 65 20 770 1130 90 + 76 90 35 10 52 412 90 + 77 88 30 10 429 789 90 + 78 88 35 20 50 410 90 + 79 87 30 10 520 880 90 + 80 85 25 10 615 975 90 + 81 85 35 30 47 407 90 + 82 75 55 20 215 575 90 + 83 72 55 10 122 482 90 + 84 70 58 20 311 671 90 + 85 68 60 30 404 764 90 + 86 66 55 10 26 386 90 + 87 65 55 20 25 385 90 + 88 65 60 30 497 857 90 + 89 63 58 10 590 950 90 + 90 60 55 10 20 380 90 + 91 60 60 10 683 1043 90 + 92 67 85 20 225 585 90 + 93 65 85 40 317 677 90 + 94 65 82 10 131 491 90 + 95 62 80 30 38 398 90 + 96 60 80 10 36 396 90 + 97 60 85 30 412 772 90 + 98 58 75 20 30 390 90 + 99 55 80 10 602 962 90 + 100 55 85 20 507 867 90 diff --git a/jsprit-instances/instances/solomon/C201.txt b/jsprit-instances/instances/solomon/C201.txt new file mode 100644 index 00000000..c9e29325 --- /dev/null +++ b/jsprit-instances/instances/solomon/C201.txt @@ -0,0 +1,110 @@ +C201 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 311 471 90 + 2 45 70 30 213 373 90 + 3 62 69 10 1167 1327 90 + 4 60 66 10 1261 1421 90 + 5 42 65 10 25 185 90 + 6 16 42 20 497 657 90 + 7 58 70 20 1073 1233 90 + 8 34 60 20 2887 3047 90 + 9 28 70 10 2601 2761 90 + 10 35 66 10 2791 2951 90 + 11 35 69 10 2698 2858 90 + 12 25 85 20 2119 2279 90 + 13 22 75 30 2405 2565 90 + 14 22 85 10 2026 2186 90 + 15 20 80 40 2216 2376 90 + 16 20 85 40 1934 2094 90 + 17 18 75 20 2311 2471 90 + 18 15 75 20 1742 1902 90 + 19 15 80 10 1837 1997 90 + 20 30 50 10 10 170 90 + 21 30 56 20 2983 3143 90 + 22 28 52 20 22 182 90 + 23 14 66 10 1643 1803 90 + 24 25 50 10 116 276 90 + 25 22 66 40 2504 2664 90 + 26 8 62 10 1545 1705 90 + 27 23 52 10 209 369 90 + 28 4 55 20 1447 1607 90 + 29 20 50 10 398 558 90 + 30 20 55 10 303 463 90 + 31 10 35 20 781 941 90 + 32 10 40 30 593 753 90 + 33 8 40 40 685 845 90 + 34 8 45 20 1346 1506 90 + 35 5 35 10 876 1036 90 + 36 5 45 10 1253 1413 90 + 37 2 40 20 971 1131 90 + 38 0 40 30 1063 1223 90 + 39 0 45 20 1158 1318 90 + 40 36 18 10 1819 1979 90 + 41 35 32 10 2758 2918 90 + 42 33 32 20 2666 2826 90 + 43 33 35 10 2573 2733 90 + 44 32 20 10 1913 2073 90 + 45 30 30 10 2105 2265 90 + 46 34 25 30 2009 2169 90 + 47 30 35 10 2480 2640 90 + 48 36 40 10 2856 3016 90 + 49 48 20 10 967 1127 90 + 50 26 32 10 2292 2452 90 + 51 25 30 10 2200 2360 90 + 52 25 35 10 2385 2545 90 + 53 44 5 20 1256 1416 90 + 54 42 10 40 1160 1320 90 + 55 42 15 10 1065 1225 90 + 56 40 5 30 1350 1510 90 + 57 38 15 40 1725 1885 90 + 58 38 5 30 1442 1602 90 + 59 38 10 10 1630 1790 90 + 60 35 5 20 1535 1695 90 + 61 50 30 10 401 561 90 + 62 50 35 20 120 280 90 + 63 50 40 50 25 185 90 + 64 48 30 10 493 653 90 + 65 44 25 10 871 1031 90 + 66 47 35 10 588 748 90 + 67 47 40 10 12 172 90 + 68 42 30 10 776 936 90 + 69 45 35 10 680 840 90 + 70 95 30 30 2321 2481 90 + 71 95 35 20 2226 2386 90 + 72 53 30 10 308 468 90 + 73 92 30 10 2414 2574 90 + 74 53 35 50 213 373 90 + 75 45 65 20 118 278 90 + 76 90 35 10 2131 2291 90 + 77 72 45 10 2900 3060 90 + 78 78 40 20 2802 2962 90 + 79 87 30 10 2608 2768 90 + 80 85 25 10 2513 2673 90 + 81 85 35 30 2703 2863 90 + 82 75 55 20 1925 2085 90 + 83 72 55 10 1832 1992 90 + 84 70 58 20 1641 1801 90 + 85 86 46 30 2029 2189 90 + 86 66 55 10 1736 1896 90 + 87 64 46 20 3097 3257 90 + 88 65 60 30 1546 1706 90 + 89 56 64 10 1355 1515 90 + 90 60 55 10 3119 3279 90 + 91 60 60 10 1451 1611 90 + 92 67 85 20 694 854 90 + 93 42 58 40 8 168 90 + 94 65 82 10 788 948 90 + 95 62 80 30 881 1041 90 + 96 62 40 10 3001 3161 90 + 97 60 85 30 597 757 90 + 98 58 75 20 978 1138 90 + 99 55 80 10 407 567 90 + 100 55 85 20 502 662 90 diff --git a/jsprit-instances/instances/solomon/C202.txt b/jsprit-instances/instances/solomon/C202.txt new file mode 100644 index 00000000..60a576de --- /dev/null +++ b/jsprit-instances/instances/solomon/C202.txt @@ -0,0 +1,110 @@ +C202 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 0 3272 90 + 2 45 70 30 0 3279 90 + 3 62 69 10 0 3270 90 + 4 60 66 10 1261 1421 90 + 5 42 65 10 0 3284 90 + 6 16 42 20 497 657 90 + 7 58 70 20 0 3273 90 + 8 34 60 20 2887 3047 90 + 9 28 70 10 2601 2761 90 + 10 35 66 10 2791 2951 90 + 11 35 69 10 2698 2858 90 + 12 25 85 20 0 3261 90 + 13 22 75 30 2405 2565 90 + 14 22 85 10 2026 2186 90 + 15 20 80 40 2216 2376 90 + 16 20 85 40 1934 2094 90 + 17 18 75 20 2311 2471 90 + 18 15 75 20 1742 1902 90 + 19 15 80 10 1837 1997 90 + 20 30 50 10 10 170 90 + 21 30 56 20 0 3288 90 + 22 28 52 20 22 182 90 + 23 14 66 10 1643 1803 90 + 24 25 50 10 116 276 90 + 25 22 66 40 2504 2664 90 + 26 8 62 10 0 3265 90 + 27 23 52 10 209 369 90 + 28 4 55 20 1447 1607 90 + 29 20 50 10 398 558 90 + 30 20 55 10 303 463 90 + 31 10 35 20 0 3266 90 + 32 10 40 30 593 753 90 + 33 8 40 40 685 845 90 + 34 8 45 20 0 3267 90 + 35 5 35 10 876 1036 90 + 36 5 45 10 1253 1413 90 + 37 2 40 20 0 3260 90 + 38 0 40 30 1063 1223 90 + 39 0 45 20 1158 1318 90 + 40 36 18 10 1819 1979 90 + 41 35 32 10 2758 2918 90 + 42 33 32 20 2666 2826 90 + 43 33 35 10 2573 2733 90 + 44 32 20 10 1913 2073 90 + 45 30 30 10 2105 2265 90 + 46 34 25 30 2009 2169 90 + 47 30 35 10 2480 2640 90 + 48 36 40 10 0 3289 90 + 49 48 20 10 967 1127 90 + 50 26 32 10 0 3277 90 + 51 25 30 10 2200 2360 90 + 52 25 35 10 0 3278 90 + 53 44 5 20 1256 1416 90 + 54 42 10 40 1160 1320 90 + 55 42 15 10 1065 1225 90 + 56 40 5 30 1350 1510 90 + 57 38 15 40 1725 1885 90 + 58 38 5 30 1442 1602 90 + 59 38 10 10 0 3259 90 + 60 35 5 20 1535 1695 90 + 61 50 30 10 401 561 90 + 62 50 35 20 120 280 90 + 63 50 40 50 25 185 90 + 64 48 30 10 493 653 90 + 65 44 25 10 871 1031 90 + 66 47 35 10 588 748 90 + 67 47 40 10 12 172 90 + 68 42 30 10 776 936 90 + 69 45 35 10 680 840 90 + 70 95 30 30 2321 2481 90 + 71 95 35 20 2226 2386 90 + 72 53 30 10 0 3276 90 + 73 92 30 10 2414 2574 90 + 74 53 35 50 213 373 90 + 75 45 65 20 0 3284 90 + 76 90 35 10 2131 2291 90 + 77 72 45 10 2900 3060 90 + 78 78 40 20 2802 2962 90 + 79 87 30 10 2608 2768 90 + 80 85 25 10 2513 2673 90 + 81 85 35 30 2703 2863 90 + 82 75 55 20 0 3264 90 + 83 72 55 10 0 3267 90 + 84 70 58 20 1641 1801 90 + 85 86 46 30 0 3253 90 + 86 66 55 10 1736 1896 90 + 87 64 46 20 3097 3257 90 + 88 65 60 30 1546 1706 90 + 89 56 64 10 1355 1515 90 + 90 60 55 10 3119 3279 90 + 91 60 60 10 0 3277 90 + 92 67 85 20 694 854 90 + 93 42 58 40 8 168 90 + 94 65 82 10 0 3259 90 + 95 62 80 30 0 3262 90 + 96 62 40 10 0 3275 90 + 97 60 85 30 597 757 90 + 98 58 75 20 0 3269 90 + 99 55 80 10 407 567 90 + 100 55 85 20 502 662 90 diff --git a/jsprit-instances/instances/solomon/C203.txt b/jsprit-instances/instances/solomon/C203.txt new file mode 100644 index 00000000..88cd64a2 --- /dev/null +++ b/jsprit-instances/instances/solomon/C203.txt @@ -0,0 +1,110 @@ +C203 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 0 3272 90 + 2 45 70 30 0 3279 90 + 3 62 69 10 0 3270 90 + 4 60 66 10 1261 1421 90 + 5 42 65 10 0 3284 90 + 6 16 42 20 497 657 90 + 7 58 70 20 0 3273 90 + 8 34 60 20 2887 3047 90 + 9 28 70 10 2601 2761 90 + 10 35 66 10 2791 2951 90 + 11 35 69 10 2698 2858 90 + 12 25 85 20 0 3261 90 + 13 22 75 30 2405 2565 90 + 14 22 85 10 0 3260 90 + 15 20 80 40 2216 2376 90 + 16 20 85 40 0 3259 90 + 17 18 75 20 2311 2471 90 + 18 15 75 20 0 3264 90 + 19 15 80 10 0 3260 90 + 20 30 50 10 0 3290 90 + 21 30 56 20 0 3288 90 + 22 28 52 20 22 182 90 + 23 14 66 10 1643 1803 90 + 24 25 50 10 0 3285 90 + 25 22 66 40 2504 2664 90 + 26 8 62 10 0 3265 90 + 27 23 52 10 209 369 90 + 28 4 55 20 0 3263 90 + 29 20 50 10 0 3280 90 + 30 20 55 10 303 463 90 + 31 10 35 20 0 3266 90 + 32 10 40 30 0 3268 90 + 33 8 40 40 685 845 90 + 34 8 45 20 0 3267 90 + 35 5 35 10 876 1036 90 + 36 5 45 10 1253 1413 90 + 37 2 40 20 0 3260 90 + 38 0 40 30 1063 1223 90 + 39 0 45 20 1158 1318 90 + 40 36 18 10 1819 1979 90 + 41 35 32 10 2758 2918 90 + 42 33 32 20 2666 2826 90 + 43 33 35 10 0 3283 90 + 44 32 20 10 1913 2073 90 + 45 30 30 10 2105 2265 90 + 46 34 25 30 0 3274 90 + 47 30 35 10 0 3281 90 + 48 36 40 10 0 3289 90 + 49 48 20 10 967 1127 90 + 50 26 32 10 0 3277 90 + 51 25 30 10 0 3275 90 + 52 25 35 10 0 3278 90 + 53 44 5 20 1256 1416 90 + 54 42 10 40 0 3259 90 + 55 42 15 10 1065 1225 90 + 56 40 5 30 1350 1510 90 + 57 38 15 40 0 3264 90 + 58 38 5 30 1442 1602 90 + 59 38 10 10 0 3259 90 + 60 35 5 20 0 3254 90 + 61 50 30 10 0 3277 90 + 62 50 35 20 120 280 90 + 63 50 40 50 0 3285 90 + 64 48 30 10 493 653 90 + 65 44 25 10 871 1031 90 + 66 47 35 10 588 748 90 + 67 47 40 10 12 172 90 + 68 42 30 10 776 936 90 + 69 45 35 10 680 840 90 + 70 95 30 30 2321 2481 90 + 71 95 35 20 0 3242 90 + 72 53 30 10 0 3276 90 + 73 92 30 10 0 3244 90 + 74 53 35 50 213 373 90 + 75 45 65 20 0 3284 90 + 76 90 35 10 2131 2291 90 + 77 72 45 10 2900 3060 90 + 78 78 40 20 2802 2962 90 + 79 87 30 10 2608 2768 90 + 80 85 25 10 2513 2673 90 + 81 85 35 30 0 3252 90 + 82 75 55 20 0 3264 90 + 83 72 55 10 0 3267 90 + 84 70 58 20 1641 1801 90 + 85 86 46 30 0 3253 90 + 86 66 55 10 0 3273 90 + 87 64 46 20 3097 3257 90 + 88 65 60 30 1546 1706 90 + 89 56 64 10 0 3278 90 + 90 60 55 10 0 3279 90 + 91 60 60 10 0 3277 90 + 92 67 85 20 694 854 90 + 93 42 58 40 8 168 90 + 94 65 82 10 0 3259 90 + 95 62 80 30 0 3262 90 + 96 62 40 10 0 3275 90 + 97 60 85 30 0 3259 90 + 98 58 75 20 0 3269 90 + 99 55 80 10 407 567 90 + 100 55 85 20 502 662 90 diff --git a/jsprit-instances/instances/solomon/C204.txt b/jsprit-instances/instances/solomon/C204.txt new file mode 100644 index 00000000..727655f0 --- /dev/null +++ b/jsprit-instances/instances/solomon/C204.txt @@ -0,0 +1,110 @@ +C204 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 0 3272 90 + 2 45 70 30 0 3279 90 + 3 62 69 10 0 3270 90 + 4 60 66 10 1261 1421 90 + 5 42 65 10 0 3284 90 + 6 16 42 20 0 3274 90 + 7 58 70 20 0 3273 90 + 8 34 60 20 2887 3047 90 + 9 28 70 10 2601 2761 90 + 10 35 66 10 0 3283 90 + 11 35 69 10 2698 2858 90 + 12 25 85 20 0 3261 90 + 13 22 75 30 2405 2565 90 + 14 22 85 10 0 3260 90 + 15 20 80 40 2216 2376 90 + 16 20 85 40 0 3259 90 + 17 18 75 20 0 3266 90 + 18 15 75 20 0 3264 90 + 19 15 80 10 0 3260 90 + 20 30 50 10 0 3290 90 + 21 30 56 20 0 3288 90 + 22 28 52 20 0 3287 90 + 23 14 66 10 1643 1803 90 + 24 25 50 10 0 3285 90 + 25 22 66 40 2504 2664 90 + 26 8 62 10 0 3265 90 + 27 23 52 10 0 3282 90 + 28 4 55 20 0 3263 90 + 29 20 50 10 0 3280 90 + 30 20 55 10 0 3279 90 + 31 10 35 20 0 3266 90 + 32 10 40 30 0 3268 90 + 33 8 40 40 0 3266 90 + 34 8 45 20 0 3267 90 + 35 5 35 10 0 3261 90 + 36 5 45 10 0 3264 90 + 37 2 40 20 0 3260 90 + 38 0 40 30 1063 1223 90 + 39 0 45 20 0 3259 90 + 40 36 18 10 0 3267 90 + 41 35 32 10 0 3281 90 + 42 33 32 20 0 3280 90 + 43 33 35 10 0 3283 90 + 44 32 20 10 1913 2073 90 + 45 30 30 10 0 3277 90 + 46 34 25 30 0 3274 90 + 47 30 35 10 0 3281 90 + 48 36 40 10 0 3289 90 + 49 48 20 10 0 3268 90 + 50 26 32 10 0 3277 90 + 51 25 30 10 0 3275 90 + 52 25 35 10 0 3278 90 + 53 44 5 20 1256 1416 90 + 54 42 10 40 0 3259 90 + 55 42 15 10 1065 1225 90 + 56 40 5 30 0 3255 90 + 57 38 15 40 0 3264 90 + 58 38 5 30 1442 1602 90 + 59 38 10 10 0 3259 90 + 60 35 5 20 0 3254 90 + 61 50 30 10 0 3277 90 + 62 50 35 20 120 280 90 + 63 50 40 50 0 3285 90 + 64 48 30 10 0 3278 90 + 65 44 25 10 0 3274 90 + 66 47 35 10 0 3283 90 + 67 47 40 10 12 172 90 + 68 42 30 10 0 3279 90 + 69 45 35 10 680 840 90 + 70 95 30 30 0 3241 90 + 71 95 35 20 0 3242 90 + 72 53 30 10 0 3276 90 + 73 92 30 10 0 3244 90 + 74 53 35 50 213 373 90 + 75 45 65 20 0 3284 90 + 76 90 35 10 2131 2291 90 + 77 72 45 10 2900 3060 90 + 78 78 40 20 0 3260 90 + 79 87 30 10 2608 2768 90 + 80 85 25 10 0 3248 90 + 81 85 35 30 0 3252 90 + 82 75 55 20 0 3264 90 + 83 72 55 10 0 3267 90 + 84 70 58 20 1641 1801 90 + 85 86 46 30 0 3253 90 + 86 66 55 10 0 3273 90 + 87 64 46 20 3097 3257 90 + 88 65 60 30 0 3273 90 + 89 56 64 10 0 3278 90 + 90 60 55 10 0 3279 90 + 91 60 60 10 0 3277 90 + 92 67 85 20 694 854 90 + 93 42 58 40 0 3291 90 + 94 65 82 10 0 3259 90 + 95 62 80 30 0 3262 90 + 96 62 40 10 0 3275 90 + 97 60 85 30 0 3259 90 + 98 58 75 20 0 3269 90 + 99 55 80 10 407 567 90 + 100 55 85 20 502 662 90 diff --git a/jsprit-instances/instances/solomon/C205.txt b/jsprit-instances/instances/solomon/C205.txt new file mode 100644 index 00000000..6ad0b365 --- /dev/null +++ b/jsprit-instances/instances/solomon/C205.txt @@ -0,0 +1,110 @@ +C205 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 231 551 90 + 2 45 70 30 133 453 90 + 3 62 69 10 1087 1407 90 + 4 60 66 10 1181 1501 90 + 5 42 65 10 15 335 90 + 6 16 42 20 417 737 90 + 7 58 70 20 993 1313 90 + 8 34 60 20 2807 3127 90 + 9 28 70 10 2521 2841 90 + 10 35 66 10 2711 3031 90 + 11 35 69 10 2618 2938 90 + 12 25 85 20 2039 2359 90 + 13 22 75 30 2325 2645 90 + 14 22 85 10 1946 2266 90 + 15 20 80 40 2136 2456 90 + 16 20 85 40 1854 2174 90 + 17 18 75 20 2231 2551 90 + 18 15 75 20 1662 1982 90 + 19 15 80 10 1757 2077 90 + 20 30 50 10 10 330 90 + 21 30 56 20 2903 3223 90 + 22 28 52 20 12 332 90 + 23 14 66 10 1563 1883 90 + 24 25 50 10 36 356 90 + 25 22 66 40 2424 2744 90 + 26 8 62 10 1465 1785 90 + 27 23 52 10 129 449 90 + 28 4 55 20 1367 1687 90 + 29 20 50 10 318 638 90 + 30 20 55 10 223 543 90 + 31 10 35 20 701 1021 90 + 32 10 40 30 513 833 90 + 33 8 40 40 605 925 90 + 34 8 45 20 1266 1586 90 + 35 5 35 10 796 1116 90 + 36 5 45 10 1173 1493 90 + 37 2 40 20 891 1211 90 + 38 0 40 30 983 1303 90 + 39 0 45 20 1078 1398 90 + 40 36 18 10 1739 2059 90 + 41 35 32 10 2678 2998 90 + 42 33 32 20 2586 2906 90 + 43 33 35 10 2493 2813 90 + 44 32 20 10 1833 2153 90 + 45 30 30 10 2025 2345 90 + 46 34 25 30 1929 2249 90 + 47 30 35 10 2400 2720 90 + 48 36 40 10 2776 3096 90 + 49 48 20 10 887 1207 90 + 50 26 32 10 2212 2532 90 + 51 25 30 10 2120 2440 90 + 52 25 35 10 2305 2625 90 + 53 44 5 20 1176 1496 90 + 54 42 10 40 1080 1400 90 + 55 42 15 10 985 1305 90 + 56 40 5 30 1270 1590 90 + 57 38 15 40 1645 1965 90 + 58 38 5 30 1362 1682 90 + 59 38 10 10 1550 1870 90 + 60 35 5 20 1455 1775 90 + 61 50 30 10 321 641 90 + 62 50 35 20 40 360 90 + 63 50 40 50 14 334 90 + 64 48 30 10 413 733 90 + 65 44 25 10 791 1111 90 + 66 47 35 10 508 828 90 + 67 47 40 10 12 332 90 + 68 42 30 10 696 1016 90 + 69 45 35 10 600 920 90 + 70 95 30 30 2241 2561 90 + 71 95 35 20 2146 2466 90 + 72 53 30 10 228 548 90 + 73 92 30 10 2334 2654 90 + 74 53 35 50 133 453 90 + 75 45 65 20 38 358 90 + 76 90 35 10 2051 2371 90 + 77 72 45 10 2820 3140 90 + 78 78 40 20 2722 3042 90 + 79 87 30 10 2528 2848 90 + 80 85 25 10 2433 2753 90 + 81 85 35 30 2623 2943 90 + 82 75 55 20 1845 2165 90 + 83 72 55 10 1752 2072 90 + 84 70 58 20 1561 1881 90 + 85 86 46 30 1949 2269 90 + 86 66 55 10 1656 1976 90 + 87 64 46 20 2955 3275 90 + 88 65 60 30 1466 1786 90 + 89 56 64 10 1275 1595 90 + 90 60 55 10 2959 3279 90 + 91 60 60 10 1371 1691 90 + 92 67 85 20 614 934 90 + 93 42 58 40 8 328 90 + 94 65 82 10 708 1028 90 + 95 62 80 30 801 1121 90 + 96 62 40 10 2921 3241 90 + 97 60 85 30 517 837 90 + 98 58 75 20 898 1218 90 + 99 55 80 10 327 647 90 + 100 55 85 20 422 742 90 diff --git a/jsprit-instances/instances/solomon/C206.txt b/jsprit-instances/instances/solomon/C206.txt new file mode 100644 index 00000000..2e81aad7 --- /dev/null +++ b/jsprit-instances/instances/solomon/C206.txt @@ -0,0 +1,110 @@ +C206 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 213 568 90 + 2 45 70 30 22 563 90 + 3 62 69 10 1030 1463 90 + 4 60 66 10 1154 1527 90 + 5 42 65 10 15 402 90 + 6 16 42 20 331 822 90 + 7 58 70 20 965 1340 90 + 8 34 60 20 2653 3280 90 + 9 28 70 10 2385 2976 90 + 10 35 66 10 2628 3113 90 + 11 35 69 10 2603 2952 90 + 12 25 85 20 1985 2412 90 + 13 22 75 30 2310 2659 90 + 14 22 85 10 1846 2365 90 + 15 20 80 40 2077 2514 90 + 16 20 85 40 1763 2264 90 + 17 18 75 20 2143 2638 90 + 18 15 75 20 1560 2083 90 + 19 15 80 10 1689 2144 90 + 20 30 50 10 10 645 90 + 21 30 56 20 2675 3288 90 + 22 28 52 20 12 505 90 + 23 14 66 10 1519 1926 90 + 24 25 50 10 23 368 90 + 25 22 66 40 2380 2787 90 + 26 8 62 10 1330 1919 90 + 27 23 52 10 93 484 90 + 28 4 55 20 1268 1785 90 + 29 20 50 10 168 787 90 + 30 20 55 10 170 595 90 + 31 10 35 20 585 1136 90 + 32 10 40 30 448 897 90 + 33 8 40 40 499 1030 90 + 34 8 45 20 1190 1661 90 + 35 5 35 10 666 1245 90 + 36 5 45 10 1076 1589 90 + 37 2 40 20 772 1329 90 + 38 0 40 30 890 1395 90 + 39 0 45 20 1036 1439 90 + 40 36 18 10 1612 2185 90 + 41 35 32 10 2599 3076 90 + 42 33 32 20 2529 2962 90 + 43 33 35 10 2463 2842 90 + 44 32 20 10 1745 2240 90 + 45 30 30 10 1932 2437 90 + 46 34 25 30 1884 2293 90 + 47 30 35 10 2348 2771 90 + 48 36 40 10 2715 3156 90 + 49 48 20 10 812 1281 90 + 50 26 32 10 2018 2725 90 + 51 25 30 10 2015 2544 90 + 52 25 35 10 2201 2728 90 + 53 44 5 20 1078 1593 90 + 54 42 10 40 998 1481 90 + 55 42 15 10 897 1392 90 + 56 40 5 30 1199 1660 90 + 57 38 15 40 1552 2057 90 + 58 38 5 30 1263 1780 90 + 59 38 10 10 1498 1921 90 + 60 35 5 20 1325 1904 90 + 61 50 30 10 223 738 90 + 62 50 35 20 18 474 90 + 63 50 40 50 14 360 90 + 64 48 30 10 246 899 90 + 65 44 25 10 704 1197 90 + 66 47 35 10 393 942 90 + 67 47 40 10 12 424 90 + 68 42 30 10 641 1070 90 + 69 45 35 10 534 985 90 + 70 95 30 30 2119 2682 90 + 71 95 35 20 2079 2532 90 + 72 53 30 10 131 644 90 + 73 92 30 10 2169 2818 90 + 74 53 35 50 87 498 90 + 75 45 65 20 15 607 90 + 76 90 35 10 2002 2419 90 + 77 72 45 10 2701 3258 90 + 78 78 40 20 2599 3164 90 + 79 87 30 10 2505 2870 90 + 80 85 25 10 2369 2816 90 + 81 85 35 30 2563 3002 90 + 82 75 55 20 1783 2226 90 + 83 72 55 10 1591 2232 90 + 84 70 58 20 1513 1928 90 + 85 86 46 30 1829 2388 90 + 86 66 55 10 1604 2027 90 + 87 64 46 20 2976 3275 90 + 88 65 60 30 1338 1913 90 + 89 56 64 10 1116 1753 90 + 90 60 55 10 2789 3279 90 + 91 60 60 10 1349 1712 90 + 92 67 85 20 518 1029 90 + 93 42 58 40 8 509 90 + 94 65 82 10 549 1186 90 + 95 62 80 30 744 1177 90 + 96 62 40 10 2713 3275 90 + 97 60 85 30 397 956 90 + 98 58 75 20 839 1276 90 + 99 55 80 10 272 701 90 + 100 55 85 20 373 790 90 diff --git a/jsprit-instances/instances/solomon/C207.txt b/jsprit-instances/instances/solomon/C207.txt new file mode 100644 index 00000000..52c30aac --- /dev/null +++ b/jsprit-instances/instances/solomon/C207.txt @@ -0,0 +1,110 @@ +C207 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 302 479 90 + 2 45 70 30 157 428 90 + 3 62 69 10 1138 1355 90 + 4 60 66 10 1247 1434 90 + 5 42 65 10 15 208 90 + 6 16 42 20 209 944 90 + 7 58 70 20 1059 1246 90 + 8 34 60 20 2035 3288 90 + 9 28 70 10 2090 3271 90 + 10 35 66 10 2311 3283 90 + 11 35 69 10 2428 3127 90 + 12 25 85 20 1772 2625 90 + 13 22 75 30 2135 2834 90 + 14 22 85 10 1586 2625 90 + 15 20 80 40 1858 2733 90 + 16 20 85 40 1512 2515 90 + 17 18 75 20 1895 2886 90 + 18 15 75 20 1299 2344 90 + 19 15 80 10 1461 2372 90 + 20 30 50 10 10 963 90 + 21 30 56 20 2062 3288 90 + 22 28 52 20 12 752 90 + 23 14 66 10 1316 2129 90 + 24 25 50 10 15 532 90 + 25 22 66 40 2177 2990 90 + 26 8 62 10 1036 2213 90 + 27 23 52 10 17 602 90 + 28 4 55 20 1010 2043 90 + 29 20 50 10 20 948 90 + 30 20 55 10 63 702 90 + 31 10 35 20 309 1412 90 + 32 10 40 30 336 1009 90 + 33 8 40 40 234 1295 90 + 34 8 45 20 954 1897 90 + 35 5 35 10 377 1534 90 + 36 5 45 10 819 1846 90 + 37 2 40 20 494 1607 90 + 38 0 40 30 637 1648 90 + 39 0 45 20 834 1641 90 + 40 36 18 10 1468 2329 90 + 41 35 32 10 2480 3195 90 + 42 33 32 20 2421 3070 90 + 43 33 35 10 2368 2937 90 + 44 32 20 10 1621 2364 90 + 45 30 30 10 1805 2564 90 + 46 34 25 30 1782 2395 90 + 47 30 35 10 2242 2877 90 + 48 36 40 10 2605 3266 90 + 49 48 20 10 812 1281 90 + 50 26 32 10 1842 2901 90 + 51 25 30 10 1883 2676 90 + 52 25 35 10 2070 2859 90 + 53 44 5 20 1078 1593 90 + 54 42 10 40 998 1481 90 + 55 42 15 10 897 1392 90 + 56 40 5 30 1083 1776 90 + 57 38 15 40 1426 2183 90 + 58 38 5 30 1133 1910 90 + 59 38 10 10 1392 2027 90 + 60 35 5 20 1180 2049 90 + 61 50 30 10 223 738 90 + 62 50 35 20 18 474 90 + 63 50 40 50 14 360 90 + 64 48 30 10 246 899 90 + 65 44 25 10 704 1197 90 + 66 47 35 10 393 942 90 + 67 47 40 10 12 424 90 + 68 42 30 10 641 1070 90 + 69 45 35 10 534 985 90 + 70 95 30 30 2119 2682 90 + 71 95 35 20 2192 2419 90 + 72 53 30 10 131 644 90 + 73 92 30 10 2169 2818 90 + 74 53 35 50 87 498 90 + 75 45 65 20 49 346 90 + 76 90 35 10 2106 2315 90 + 77 72 45 10 2701 3258 90 + 78 78 40 20 2599 3164 90 + 79 87 30 10 2505 2870 90 + 80 85 25 10 2369 2816 90 + 81 85 35 30 2563 3002 90 + 82 75 55 20 1894 2115 90 + 83 72 55 10 1751 2072 90 + 84 70 58 20 1617 1824 90 + 85 86 46 30 1969 2248 90 + 86 66 55 10 1710 1921 90 + 87 64 46 20 2976 3275 90 + 88 65 60 30 1482 1769 90 + 89 56 64 10 1275 1594 90 + 90 60 55 10 2789 3279 90 + 91 60 60 10 1440 1621 90 + 92 67 85 20 646 901 90 + 93 42 58 40 8 258 90 + 94 65 82 10 708 1027 90 + 95 62 80 30 852 1069 90 + 96 62 40 10 2713 3275 90 + 97 60 85 30 537 816 90 + 98 58 75 20 948 1167 90 + 99 55 80 10 379 594 90 + 100 55 85 20 477 686 90 diff --git a/jsprit-instances/instances/solomon/C208.txt b/jsprit-instances/instances/solomon/C208.txt new file mode 100644 index 00000000..df0e93e8 --- /dev/null +++ b/jsprit-instances/instances/solomon/C208.txt @@ -0,0 +1,110 @@ +C208 + +VEHICLE +NUMBER CAPACITY + 25 700 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 3390 0 + 1 52 75 10 71 711 90 + 2 45 70 30 20 660 90 + 3 62 69 10 927 1567 90 + 4 60 66 10 1021 1661 90 + 5 42 65 10 15 655 90 + 6 16 42 20 257 897 90 + 7 58 70 20 833 1473 90 + 8 34 60 20 2647 3287 90 + 9 28 70 10 2361 3001 90 + 10 35 66 10 2551 3191 90 + 11 35 69 10 2458 3098 90 + 12 25 85 20 1879 2519 90 + 13 22 75 30 2165 2805 90 + 14 22 85 10 1786 2426 90 + 15 20 80 40 1976 2616 90 + 16 20 85 40 1694 2334 90 + 17 18 75 20 2071 2711 90 + 18 15 75 20 1502 2142 90 + 19 15 80 10 1597 2237 90 + 20 30 50 10 10 650 90 + 21 30 56 20 2648 3288 90 + 22 28 52 20 12 652 90 + 23 14 66 10 1403 2043 90 + 24 25 50 10 15 655 90 + 25 22 66 40 2264 2904 90 + 26 8 62 10 1305 1945 90 + 27 23 52 10 17 657 90 + 28 4 55 20 1207 1847 90 + 29 20 50 10 158 798 90 + 30 20 55 10 63 703 90 + 31 10 35 20 541 1181 90 + 32 10 40 30 353 993 90 + 33 8 40 40 445 1085 90 + 34 8 45 20 1106 1746 90 + 35 5 35 10 636 1276 90 + 36 5 45 10 1013 1653 90 + 37 2 40 20 731 1371 90 + 38 0 40 30 823 1463 90 + 39 0 45 20 918 1558 90 + 40 36 18 10 1579 2219 90 + 41 35 32 10 2518 3158 90 + 42 33 32 20 2426 3066 90 + 43 33 35 10 2333 2973 90 + 44 32 20 10 1673 2313 90 + 45 30 30 10 1865 2505 90 + 46 34 25 30 1769 2409 90 + 47 30 35 10 2240 2880 90 + 48 36 40 10 2616 3256 90 + 49 48 20 10 727 1367 90 + 50 26 32 10 2052 2692 90 + 51 25 30 10 1960 2600 90 + 52 25 35 10 2145 2785 90 + 53 44 5 20 1016 1656 90 + 54 42 10 40 920 1560 90 + 55 42 15 10 825 1465 90 + 56 40 5 30 1110 1750 90 + 57 38 15 40 1485 2125 90 + 58 38 5 30 1202 1842 90 + 59 38 10 10 1390 2030 90 + 60 35 5 20 1295 1935 90 + 61 50 30 10 161 801 90 + 62 50 35 20 18 658 90 + 63 50 40 50 14 654 90 + 64 48 30 10 253 893 90 + 65 44 25 10 631 1271 90 + 66 47 35 10 348 988 90 + 67 47 40 10 12 652 90 + 68 42 30 10 536 1176 90 + 69 45 35 10 440 1080 90 + 70 95 30 30 2081 2721 90 + 71 95 35 20 1986 2626 90 + 72 53 30 10 68 708 90 + 73 92 30 10 2174 2814 90 + 74 53 35 50 19 659 90 + 75 45 65 20 15 655 90 + 76 90 35 10 1891 2531 90 + 77 72 45 10 2627 3267 90 + 78 78 40 20 2562 3202 90 + 79 87 30 10 2368 3008 90 + 80 85 25 10 2273 2913 90 + 81 85 35 30 2463 3103 90 + 82 75 55 20 1685 2325 90 + 83 72 55 10 1592 2232 90 + 84 70 58 20 1401 2041 90 + 85 86 46 30 1789 2429 90 + 86 66 55 10 1496 2136 90 + 87 64 46 20 2635 3275 90 + 88 65 60 30 1306 1946 90 + 89 56 64 10 1115 1755 90 + 90 60 55 10 2639 3279 90 + 91 60 60 10 1211 1851 90 + 92 67 85 20 454 1094 90 + 93 42 58 40 8 648 90 + 94 65 82 10 548 1188 90 + 95 62 80 30 641 1281 90 + 96 62 40 10 2635 3275 90 + 97 60 85 30 357 997 90 + 98 58 75 20 738 1378 90 + 99 55 80 10 167 807 90 + 100 55 85 20 262 902 90 diff --git a/jsprit-instances/instances/solomon/R101.txt b/jsprit-instances/instances/solomon/R101.txt new file mode 100644 index 00000000..8a9b6e59 --- /dev/null +++ b/jsprit-instances/instances/solomon/R101.txt @@ -0,0 +1,110 @@ +R101 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 161 171 10 + 2 35 17 7 50 60 10 + 3 55 45 13 116 126 10 + 4 55 20 19 149 159 10 + 5 15 30 26 34 44 10 + 6 25 30 3 99 109 10 + 7 20 50 5 81 91 10 + 8 10 43 9 95 105 10 + 9 55 60 16 97 107 10 + 10 30 60 16 124 134 10 + 11 20 65 12 67 77 10 + 12 50 35 19 63 73 10 + 13 30 25 23 159 169 10 + 14 15 10 20 32 42 10 + 15 30 5 8 61 71 10 + 16 10 20 19 75 85 10 + 17 5 30 2 157 167 10 + 18 20 40 12 87 97 10 + 19 15 60 17 76 86 10 + 20 45 65 9 126 136 10 + 21 45 20 11 62 72 10 + 22 45 10 18 97 107 10 + 23 55 5 29 68 78 10 + 24 65 35 3 153 163 10 + 25 65 20 6 172 182 10 + 26 45 30 17 132 142 10 + 27 35 40 16 37 47 10 + 28 41 37 16 39 49 10 + 29 64 42 9 63 73 10 + 30 40 60 21 71 81 10 + 31 31 52 27 50 60 10 + 32 35 69 23 141 151 10 + 33 53 52 11 37 47 10 + 34 65 55 14 117 127 10 + 35 63 65 8 143 153 10 + 36 2 60 5 41 51 10 + 37 20 20 8 134 144 10 + 38 5 5 16 83 93 10 + 39 60 12 31 44 54 10 + 40 40 25 9 85 95 10 + 41 42 7 5 97 107 10 + 42 24 12 5 31 41 10 + 43 23 3 7 132 142 10 + 44 11 14 18 69 79 10 + 45 6 38 16 32 42 10 + 46 2 48 1 117 127 10 + 47 8 56 27 51 61 10 + 48 13 52 36 165 175 10 + 49 6 68 30 108 118 10 + 50 47 47 13 124 134 10 + 51 49 58 10 88 98 10 + 52 27 43 9 52 62 10 + 53 37 31 14 95 105 10 + 54 57 29 18 140 150 10 + 55 63 23 2 136 146 10 + 56 53 12 6 130 140 10 + 57 32 12 7 101 111 10 + 58 36 26 18 200 210 10 + 59 21 24 28 18 28 10 + 60 17 34 3 162 172 10 + 61 12 24 13 76 86 10 + 62 24 58 19 58 68 10 + 63 27 69 10 34 44 10 + 64 15 77 9 73 83 10 + 65 62 77 20 51 61 10 + 66 49 73 25 127 137 10 + 67 67 5 25 83 93 10 + 68 56 39 36 142 152 10 + 69 37 47 6 50 60 10 + 70 37 56 5 182 192 10 + 71 57 68 15 77 87 10 + 72 47 16 25 35 45 10 + 73 44 17 9 78 88 10 + 74 46 13 8 149 159 10 + 75 49 11 18 69 79 10 + 76 49 42 13 73 83 10 + 77 53 43 14 179 189 10 + 78 61 52 3 96 106 10 + 79 57 48 23 92 102 10 + 80 56 37 6 182 192 10 + 81 55 54 26 94 104 10 + 82 15 47 16 55 65 10 + 83 14 37 11 44 54 10 + 84 11 31 7 101 111 10 + 85 16 22 41 91 101 10 + 86 4 18 35 94 104 10 + 87 28 18 26 93 103 10 + 88 26 52 9 74 84 10 + 89 26 35 15 176 186 10 + 90 31 67 3 95 105 10 + 91 15 19 1 160 170 10 + 92 22 22 2 18 28 10 + 93 18 24 22 188 198 10 + 94 26 27 27 100 110 10 + 95 25 24 20 39 49 10 + 96 22 27 11 135 145 10 + 97 25 21 12 133 143 10 + 98 19 21 10 58 68 10 + 99 20 26 9 83 93 10 + 100 18 18 17 185 195 10 diff --git a/jsprit-instances/instances/solomon/R102.txt b/jsprit-instances/instances/solomon/R102.txt new file mode 100644 index 00000000..c2fcc4ee --- /dev/null +++ b/jsprit-instances/instances/solomon/R102.txt @@ -0,0 +1,110 @@ +R102 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 149 159 10 + 5 15 30 26 0 199 10 + 6 25 30 3 99 109 10 + 7 20 50 5 0 198 10 + 8 10 43 9 95 105 10 + 9 55 60 16 97 107 10 + 10 30 60 16 124 134 10 + 11 20 65 12 67 77 10 + 12 50 35 19 0 205 10 + 13 30 25 23 159 169 10 + 14 15 10 20 32 42 10 + 15 30 5 8 61 71 10 + 16 10 20 19 75 85 10 + 17 5 30 2 157 167 10 + 18 20 40 12 87 97 10 + 19 15 60 17 76 86 10 + 20 45 65 9 126 136 10 + 21 45 20 11 0 201 10 + 22 45 10 18 97 107 10 + 23 55 5 29 68 78 10 + 24 65 35 3 153 163 10 + 25 65 20 6 172 182 10 + 26 45 30 17 0 208 10 + 27 35 40 16 37 47 10 + 28 41 37 16 39 49 10 + 29 64 42 9 63 73 10 + 30 40 60 21 71 81 10 + 31 31 52 27 0 202 10 + 32 35 69 23 141 151 10 + 33 53 52 11 37 47 10 + 34 65 55 14 0 183 10 + 35 63 65 8 143 153 10 + 36 2 60 5 41 51 10 + 37 20 20 8 0 198 10 + 38 5 5 16 83 93 10 + 39 60 12 31 44 54 10 + 40 40 25 9 85 95 10 + 41 42 7 5 97 107 10 + 42 24 12 5 31 41 10 + 43 23 3 7 132 142 10 + 44 11 14 18 69 79 10 + 45 6 38 16 32 42 10 + 46 2 48 1 117 127 10 + 47 8 56 27 51 61 10 + 48 13 52 36 0 192 10 + 49 6 68 30 108 118 10 + 50 47 47 13 0 203 10 + 51 49 58 10 88 98 10 + 52 27 43 9 0 208 10 + 53 37 31 14 95 105 10 + 54 57 29 18 140 150 10 + 55 63 23 2 136 146 10 + 56 53 12 6 130 140 10 + 57 32 12 7 101 111 10 + 58 36 26 18 200 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 162 172 10 + 61 12 24 13 76 86 10 + 62 24 58 19 58 68 10 + 63 27 69 10 34 44 10 + 64 15 77 9 73 83 10 + 65 62 77 20 51 61 10 + 66 49 73 25 127 137 10 + 67 67 5 25 83 93 10 + 68 56 39 36 142 152 10 + 69 37 47 6 50 60 10 + 70 37 56 5 182 192 10 + 71 57 68 15 77 87 10 + 72 47 16 25 0 197 10 + 73 44 17 9 78 88 10 + 74 46 13 8 149 159 10 + 75 49 11 18 0 192 10 + 76 49 42 13 73 83 10 + 77 53 43 14 179 189 10 + 78 61 52 3 96 106 10 + 79 57 48 23 92 102 10 + 80 56 37 6 182 192 10 + 81 55 54 26 94 104 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 101 111 10 + 85 16 22 41 0 196 10 + 86 4 18 35 94 104 10 + 87 28 18 26 93 103 10 + 88 26 52 9 74 84 10 + 89 26 35 15 176 186 10 + 90 31 67 3 95 105 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 28 10 + 93 18 24 22 188 198 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 133 143 10 + 98 19 21 10 0 198 10 + 99 20 26 9 83 93 10 + 100 18 18 17 185 195 10 diff --git a/jsprit-instances/instances/solomon/R103.txt b/jsprit-instances/instances/solomon/R103.txt new file mode 100644 index 00000000..fd96390b --- /dev/null +++ b/jsprit-instances/instances/solomon/R103.txt @@ -0,0 +1,110 @@ +R103 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 149 159 10 + 5 15 30 26 0 199 10 + 6 25 30 3 99 109 10 + 7 20 50 5 0 198 10 + 8 10 43 9 95 105 10 + 9 55 60 16 97 107 10 + 10 30 60 16 124 134 10 + 11 20 65 12 67 77 10 + 12 50 35 19 0 205 10 + 13 30 25 23 159 169 10 + 14 15 10 20 0 187 10 + 15 30 5 8 61 71 10 + 16 10 20 19 0 190 10 + 17 5 30 2 157 167 10 + 18 20 40 12 0 204 10 + 19 15 60 17 0 187 10 + 20 45 65 9 0 188 10 + 21 45 20 11 0 201 10 + 22 45 10 18 97 107 10 + 23 55 5 29 68 78 10 + 24 65 35 3 0 190 10 + 25 65 20 6 172 182 10 + 26 45 30 17 0 208 10 + 27 35 40 16 37 47 10 + 28 41 37 16 0 213 10 + 29 64 42 9 0 190 10 + 30 40 60 21 71 81 10 + 31 31 52 27 0 202 10 + 32 35 69 23 0 186 10 + 33 53 52 11 37 47 10 + 34 65 55 14 0 183 10 + 35 63 65 8 143 153 10 + 36 2 60 5 41 51 10 + 37 20 20 8 0 198 10 + 38 5 5 16 83 93 10 + 39 60 12 31 44 54 10 + 40 40 25 9 85 95 10 + 41 42 7 5 97 107 10 + 42 24 12 5 31 41 10 + 43 23 3 7 0 185 10 + 44 11 14 18 69 79 10 + 45 6 38 16 32 42 10 + 46 2 48 1 0 184 10 + 47 8 56 27 0 185 10 + 48 13 52 36 0 192 10 + 49 6 68 30 108 118 10 + 50 47 47 13 0 203 10 + 51 49 58 10 0 193 10 + 52 27 43 9 0 208 10 + 53 37 31 14 95 105 10 + 54 57 29 18 0 197 10 + 55 63 23 2 136 146 10 + 56 53 12 6 130 140 10 + 57 32 12 7 0 196 10 + 58 36 26 18 200 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 0 201 10 + 61 12 24 13 0 194 10 + 62 24 58 19 58 68 10 + 63 27 69 10 0 185 10 + 64 15 77 9 73 83 10 + 65 62 77 20 51 61 10 + 66 49 73 25 127 137 10 + 67 67 5 25 83 93 10 + 68 56 39 36 142 152 10 + 69 37 47 6 50 60 10 + 70 37 56 5 182 192 10 + 71 57 68 15 0 180 10 + 72 47 16 25 0 197 10 + 73 44 17 9 0 199 10 + 74 46 13 8 149 159 10 + 75 49 11 18 0 192 10 + 76 49 42 13 73 83 10 + 77 53 43 14 179 189 10 + 78 61 52 3 96 106 10 + 79 57 48 23 92 102 10 + 80 56 37 6 182 192 10 + 81 55 54 26 0 192 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 101 111 10 + 85 16 22 41 0 196 10 + 86 4 18 35 0 184 10 + 87 28 18 26 93 103 10 + 88 26 52 9 74 84 10 + 89 26 35 15 0 211 10 + 90 31 67 3 0 187 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 28 10 + 93 18 24 22 188 198 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 0 202 10 + 98 19 21 10 0 198 10 + 99 20 26 9 83 93 10 + 100 18 18 17 185 195 10 diff --git a/jsprit-instances/instances/solomon/R104.txt b/jsprit-instances/instances/solomon/R104.txt new file mode 100644 index 00000000..f77f1cfd --- /dev/null +++ b/jsprit-instances/instances/solomon/R104.txt @@ -0,0 +1,110 @@ +R104 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 149 159 10 + 5 15 30 26 0 199 10 + 6 25 30 3 0 208 10 + 7 20 50 5 0 198 10 + 8 10 43 9 95 105 10 + 9 55 60 16 97 107 10 + 10 30 60 16 0 194 10 + 11 20 65 12 67 77 10 + 12 50 35 19 0 205 10 + 13 30 25 23 159 169 10 + 14 15 10 20 0 187 10 + 15 30 5 8 61 71 10 + 16 10 20 19 0 190 10 + 17 5 30 2 0 189 10 + 18 20 40 12 0 204 10 + 19 15 60 17 0 187 10 + 20 45 65 9 0 188 10 + 21 45 20 11 0 201 10 + 22 45 10 18 0 193 10 + 23 55 5 29 68 78 10 + 24 65 35 3 0 190 10 + 25 65 20 6 172 182 10 + 26 45 30 17 0 208 10 + 27 35 40 16 0 215 10 + 28 41 37 16 0 213 10 + 29 64 42 9 0 190 10 + 30 40 60 21 0 194 10 + 31 31 52 27 0 202 10 + 32 35 69 23 0 186 10 + 33 53 52 11 0 195 10 + 34 65 55 14 0 183 10 + 35 63 65 8 0 178 10 + 36 2 60 5 0 178 10 + 37 20 20 8 0 198 10 + 38 5 5 16 83 93 10 + 39 60 12 31 0 186 10 + 40 40 25 9 0 208 10 + 41 42 7 5 0 191 10 + 42 24 12 5 0 194 10 + 43 23 3 7 0 185 10 + 44 11 14 18 69 79 10 + 45 6 38 16 0 190 10 + 46 2 48 1 0 184 10 + 47 8 56 27 0 185 10 + 48 13 52 36 0 192 10 + 49 6 68 30 0 176 10 + 50 47 47 13 0 203 10 + 51 49 58 10 0 193 10 + 52 27 43 9 0 208 10 + 53 37 31 14 95 105 10 + 54 57 29 18 0 197 10 + 55 63 23 2 136 146 10 + 56 53 12 6 0 190 10 + 57 32 12 7 0 196 10 + 58 36 26 18 200 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 0 201 10 + 61 12 24 13 0 194 10 + 62 24 58 19 58 68 10 + 63 27 69 10 0 185 10 + 64 15 77 9 0 173 10 + 65 62 77 20 0 170 10 + 66 49 73 25 0 179 10 + 67 67 5 25 83 93 10 + 68 56 39 36 0 198 10 + 69 37 47 6 50 60 10 + 70 37 56 5 0 198 10 + 71 57 68 15 0 180 10 + 72 47 16 25 0 197 10 + 73 44 17 9 0 199 10 + 74 46 13 8 149 159 10 + 75 49 11 18 0 192 10 + 76 49 42 13 73 83 10 + 77 53 43 14 179 189 10 + 78 61 52 3 0 188 10 + 79 57 48 23 92 102 10 + 80 56 37 6 0 198 10 + 81 55 54 26 0 192 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 101 111 10 + 85 16 22 41 0 196 10 + 86 4 18 35 0 184 10 + 87 28 18 26 93 103 10 + 88 26 52 9 0 200 10 + 89 26 35 15 0 211 10 + 90 31 67 3 0 187 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 28 10 + 93 18 24 22 0 199 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 0 202 10 + 98 19 21 10 0 198 10 + 99 20 26 9 83 93 10 + 100 18 18 17 185 195 10 diff --git a/jsprit-instances/instances/solomon/R105.txt b/jsprit-instances/instances/solomon/R105.txt new file mode 100644 index 00000000..8d8f97a2 --- /dev/null +++ b/jsprit-instances/instances/solomon/R105.txt @@ -0,0 +1,110 @@ +R105 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 151 181 10 + 2 35 17 7 40 70 10 + 3 55 45 13 106 136 10 + 4 55 20 19 139 169 10 + 5 15 30 26 24 54 10 + 6 25 30 3 89 119 10 + 7 20 50 5 71 101 10 + 8 10 43 9 85 115 10 + 9 55 60 16 87 117 10 + 10 30 60 16 114 144 10 + 11 20 65 12 57 87 10 + 12 50 35 19 53 83 10 + 13 30 25 23 149 179 10 + 14 15 10 20 32 62 10 + 15 30 5 8 51 81 10 + 16 10 20 19 65 95 10 + 17 5 30 2 147 177 10 + 18 20 40 12 77 107 10 + 19 15 60 17 66 96 10 + 20 45 65 9 116 146 10 + 21 45 20 11 52 82 10 + 22 45 10 18 87 117 10 + 23 55 5 29 58 88 10 + 24 65 35 3 143 173 10 + 25 65 20 6 156 186 10 + 26 45 30 17 122 152 10 + 27 35 40 16 27 57 10 + 28 41 37 16 29 59 10 + 29 64 42 9 53 83 10 + 30 40 60 21 61 91 10 + 31 31 52 27 40 70 10 + 32 35 69 23 131 161 10 + 33 53 52 11 27 57 10 + 34 65 55 14 107 137 10 + 35 63 65 8 133 163 10 + 36 2 60 5 41 71 10 + 37 20 20 8 124 154 10 + 38 5 5 16 73 103 10 + 39 60 12 31 34 64 10 + 40 40 25 9 75 105 10 + 41 42 7 5 87 117 10 + 42 24 12 5 25 55 10 + 43 23 3 7 122 152 10 + 44 11 14 18 59 89 10 + 45 6 38 16 29 59 10 + 46 2 48 1 107 137 10 + 47 8 56 27 41 71 10 + 48 13 52 36 155 185 10 + 49 6 68 30 98 128 10 + 50 47 47 13 114 144 10 + 51 49 58 10 78 108 10 + 52 27 43 9 42 72 10 + 53 37 31 14 85 115 10 + 54 57 29 18 130 160 10 + 55 63 23 2 126 156 10 + 56 53 12 6 120 150 10 + 57 32 12 7 91 121 10 + 58 36 26 18 180 210 10 + 59 21 24 28 17 47 10 + 60 17 34 3 152 182 10 + 61 12 24 13 66 96 10 + 62 24 58 19 48 78 10 + 63 27 69 10 34 64 10 + 64 15 77 9 63 93 10 + 65 62 77 20 49 79 10 + 66 49 73 25 117 147 10 + 67 67 5 25 73 103 10 + 68 56 39 36 132 162 10 + 69 37 47 6 40 70 10 + 70 37 56 5 168 198 10 + 71 57 68 15 67 97 10 + 72 47 16 25 25 55 10 + 73 44 17 9 68 98 10 + 74 46 13 8 139 169 10 + 75 49 11 18 59 89 10 + 76 49 42 13 63 93 10 + 77 53 43 14 169 199 10 + 78 61 52 3 86 116 10 + 79 57 48 23 82 112 10 + 80 56 37 6 168 198 10 + 81 55 54 26 84 114 10 + 82 15 47 16 45 75 10 + 83 14 37 11 34 64 10 + 84 11 31 7 91 121 10 + 85 16 22 41 81 111 10 + 86 4 18 35 84 114 10 + 87 28 18 26 83 113 10 + 88 26 52 9 64 94 10 + 89 26 35 15 166 196 10 + 90 31 67 3 85 115 10 + 91 15 19 1 150 180 10 + 92 22 22 2 18 48 10 + 93 18 24 22 169 199 10 + 94 26 27 27 90 120 10 + 95 25 24 20 29 59 10 + 96 22 27 11 125 155 10 + 97 25 21 12 123 153 10 + 98 19 21 10 48 78 10 + 99 20 26 9 73 103 10 + 100 18 18 17 165 195 10 diff --git a/jsprit-instances/instances/solomon/R106.txt b/jsprit-instances/instances/solomon/R106.txt new file mode 100644 index 00000000..cce29ba8 --- /dev/null +++ b/jsprit-instances/instances/solomon/R106.txt @@ -0,0 +1,110 @@ +R106 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 139 169 10 + 5 15 30 26 0 199 10 + 6 25 30 3 89 119 10 + 7 20 50 5 0 198 10 + 8 10 43 9 85 115 10 + 9 55 60 16 87 117 10 + 10 30 60 16 114 144 10 + 11 20 65 12 57 87 10 + 12 50 35 19 0 205 10 + 13 30 25 23 149 179 10 + 14 15 10 20 32 62 10 + 15 30 5 8 51 81 10 + 16 10 20 19 65 95 10 + 17 5 30 2 147 177 10 + 18 20 40 12 77 107 10 + 19 15 60 17 66 96 10 + 20 45 65 9 116 146 10 + 21 45 20 11 0 201 10 + 22 45 10 18 87 117 10 + 23 55 5 29 58 88 10 + 24 65 35 3 143 173 10 + 25 65 20 6 156 186 10 + 26 45 30 17 0 208 10 + 27 35 40 16 27 57 10 + 28 41 37 16 29 59 10 + 29 64 42 9 53 83 10 + 30 40 60 21 61 91 10 + 31 31 52 27 0 202 10 + 32 35 69 23 131 161 10 + 33 53 52 11 27 57 10 + 34 65 55 14 0 183 10 + 35 63 65 8 133 163 10 + 36 2 60 5 41 71 10 + 37 20 20 8 0 198 10 + 38 5 5 16 73 103 10 + 39 60 12 31 34 64 10 + 40 40 25 9 75 105 10 + 41 42 7 5 87 117 10 + 42 24 12 5 25 55 10 + 43 23 3 7 122 152 10 + 44 11 14 18 59 89 10 + 45 6 38 16 29 59 10 + 46 2 48 1 107 137 10 + 47 8 56 27 41 71 10 + 48 13 52 36 0 192 10 + 49 6 68 30 98 128 10 + 50 47 47 13 0 203 10 + 51 49 58 10 78 108 10 + 52 27 43 9 0 208 10 + 53 37 31 14 85 115 10 + 54 57 29 18 130 160 10 + 55 63 23 2 126 156 10 + 56 53 12 6 120 150 10 + 57 32 12 7 91 121 10 + 58 36 26 18 180 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 152 182 10 + 61 12 24 13 66 96 10 + 62 24 58 19 48 78 10 + 63 27 69 10 34 64 10 + 64 15 77 9 63 93 10 + 65 62 77 20 49 79 10 + 66 49 73 25 117 147 10 + 67 67 5 25 73 103 10 + 68 56 39 36 132 162 10 + 69 37 47 6 40 70 10 + 70 37 56 5 168 198 10 + 71 57 68 15 67 97 10 + 72 47 16 25 0 197 10 + 73 44 17 9 68 98 10 + 74 46 13 8 139 169 10 + 75 49 11 18 0 192 10 + 76 49 42 13 63 93 10 + 77 53 43 14 169 199 10 + 78 61 52 3 86 116 10 + 79 57 48 23 82 112 10 + 80 56 37 6 168 198 10 + 81 55 54 26 84 114 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 91 121 10 + 85 16 22 41 0 196 10 + 86 4 18 35 84 114 10 + 87 28 18 26 83 113 10 + 88 26 52 9 64 94 10 + 89 26 35 15 166 196 10 + 90 31 67 3 85 115 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 48 10 + 93 18 24 22 169 199 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 123 153 10 + 98 19 21 10 0 198 10 + 99 20 26 9 73 103 10 + 100 18 18 17 165 195 10 diff --git a/jsprit-instances/instances/solomon/R107.txt b/jsprit-instances/instances/solomon/R107.txt new file mode 100644 index 00000000..ae23ba8f --- /dev/null +++ b/jsprit-instances/instances/solomon/R107.txt @@ -0,0 +1,110 @@ +R107 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 139 169 10 + 5 15 30 26 0 199 10 + 6 25 30 3 89 119 10 + 7 20 50 5 0 198 10 + 8 10 43 9 85 115 10 + 9 55 60 16 87 117 10 + 10 30 60 16 114 144 10 + 11 20 65 12 57 87 10 + 12 50 35 19 0 205 10 + 13 30 25 23 149 179 10 + 14 15 10 20 0 187 10 + 15 30 5 8 51 81 10 + 16 10 20 19 0 190 10 + 17 5 30 2 147 177 10 + 18 20 40 12 0 204 10 + 19 15 60 17 0 187 10 + 20 45 65 9 0 188 10 + 21 45 20 11 0 201 10 + 22 45 10 18 87 117 10 + 23 55 5 29 58 88 10 + 24 65 35 3 0 190 10 + 25 65 20 6 156 186 10 + 26 45 30 17 0 208 10 + 27 35 40 16 27 57 10 + 28 41 37 16 0 213 10 + 29 64 42 9 0 190 10 + 30 40 60 21 61 91 10 + 31 31 52 27 0 202 10 + 32 35 69 23 0 186 10 + 33 53 52 11 27 57 10 + 34 65 55 14 0 183 10 + 35 63 65 8 133 163 10 + 36 2 60 5 41 71 10 + 37 20 20 8 0 198 10 + 38 5 5 16 73 103 10 + 39 60 12 31 34 64 10 + 40 40 25 9 75 105 10 + 41 42 7 5 87 117 10 + 42 24 12 5 25 55 10 + 43 23 3 7 0 185 10 + 44 11 14 18 59 89 10 + 45 6 38 16 29 59 10 + 46 2 48 1 0 184 10 + 47 8 56 27 0 185 10 + 48 13 52 36 0 192 10 + 49 6 68 30 98 128 10 + 50 47 47 13 0 203 10 + 51 49 58 10 0 193 10 + 52 27 43 9 0 208 10 + 53 37 31 14 85 115 10 + 54 57 29 18 0 197 10 + 55 63 23 2 126 156 10 + 56 53 12 6 120 150 10 + 57 32 12 7 0 196 10 + 58 36 26 18 180 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 0 201 10 + 61 12 24 13 0 194 10 + 62 24 58 19 48 78 10 + 63 27 69 10 0 185 10 + 64 15 77 9 63 93 10 + 65 62 77 20 49 79 10 + 66 49 73 25 117 147 10 + 67 67 5 25 73 103 10 + 68 56 39 36 132 162 10 + 69 37 47 6 40 70 10 + 70 37 56 5 168 198 10 + 71 57 68 15 0 180 10 + 72 47 16 25 0 197 10 + 73 44 17 9 0 199 10 + 74 46 13 8 139 169 10 + 75 49 11 18 0 192 10 + 76 49 42 13 63 93 10 + 77 53 43 14 169 199 10 + 78 61 52 3 86 116 10 + 79 57 48 23 82 112 10 + 80 56 37 6 168 198 10 + 81 55 54 26 0 192 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 91 121 10 + 85 16 22 41 0 196 10 + 86 4 18 35 0 184 10 + 87 28 18 26 83 113 10 + 88 26 52 9 64 94 10 + 89 26 35 15 0 211 10 + 90 31 67 3 0 187 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 48 10 + 93 18 24 22 169 199 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 0 202 10 + 98 19 21 10 0 198 10 + 99 20 26 9 73 103 10 + 100 18 18 17 165 195 10 diff --git a/jsprit-instances/instances/solomon/R108.txt b/jsprit-instances/instances/solomon/R108.txt new file mode 100644 index 00000000..0845d845 --- /dev/null +++ b/jsprit-instances/instances/solomon/R108.txt @@ -0,0 +1,110 @@ +R108 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 0 204 10 + 2 35 17 7 0 202 10 + 3 55 45 13 0 197 10 + 4 55 20 19 139 169 10 + 5 15 30 26 0 199 10 + 6 25 30 3 0 208 10 + 7 20 50 5 0 198 10 + 8 10 43 9 85 115 10 + 9 55 60 16 87 117 10 + 10 30 60 16 0 194 10 + 11 20 65 12 57 87 10 + 12 50 35 19 0 205 10 + 13 30 25 23 149 179 10 + 14 15 10 20 0 187 10 + 15 30 5 8 51 81 10 + 16 10 20 19 0 190 10 + 17 5 30 2 0 189 10 + 18 20 40 12 0 204 10 + 19 15 60 17 0 187 10 + 20 45 65 9 0 188 10 + 21 45 20 11 0 201 10 + 22 45 10 18 0 193 10 + 23 55 5 29 58 88 10 + 24 65 35 3 0 190 10 + 25 65 20 6 156 186 10 + 26 45 30 17 0 208 10 + 27 35 40 16 0 215 10 + 28 41 37 16 0 213 10 + 29 64 42 9 0 190 10 + 30 40 60 21 0 194 10 + 31 31 52 27 0 202 10 + 32 35 69 23 0 186 10 + 33 53 52 11 0 195 10 + 34 65 55 14 0 183 10 + 35 63 65 8 0 178 10 + 36 2 60 5 0 178 10 + 37 20 20 8 0 198 10 + 38 5 5 16 73 103 10 + 39 60 12 31 0 186 10 + 40 40 25 9 0 208 10 + 41 42 7 5 0 191 10 + 42 24 12 5 0 194 10 + 43 23 3 7 0 185 10 + 44 11 14 18 59 89 10 + 45 6 38 16 0 190 10 + 46 2 48 1 0 184 10 + 47 8 56 27 0 185 10 + 48 13 52 36 0 192 10 + 49 6 68 30 0 176 10 + 50 47 47 13 0 203 10 + 51 49 58 10 0 193 10 + 52 27 43 9 0 208 10 + 53 37 31 14 85 115 10 + 54 57 29 18 0 197 10 + 55 63 23 2 126 156 10 + 56 53 12 6 0 190 10 + 57 32 12 7 0 196 10 + 58 36 26 18 180 210 10 + 59 21 24 28 0 202 10 + 60 17 34 3 0 201 10 + 61 12 24 13 0 194 10 + 62 24 58 19 48 78 10 + 63 27 69 10 0 185 10 + 64 15 77 9 0 173 10 + 65 62 77 20 0 170 10 + 66 49 73 25 0 179 10 + 67 67 5 25 73 103 10 + 68 56 39 36 0 198 10 + 69 37 47 6 40 70 10 + 70 37 56 5 0 198 10 + 71 57 68 15 0 180 10 + 72 47 16 25 0 197 10 + 73 44 17 9 0 199 10 + 74 46 13 8 139 169 10 + 75 49 11 18 0 192 10 + 76 49 42 13 63 93 10 + 77 53 43 14 169 199 10 + 78 61 52 3 0 188 10 + 79 57 48 23 82 112 10 + 80 56 37 6 0 198 10 + 81 55 54 26 0 192 10 + 82 15 47 16 0 196 10 + 83 14 37 11 0 198 10 + 84 11 31 7 91 121 10 + 85 16 22 41 0 196 10 + 86 4 18 35 0 184 10 + 87 28 18 26 83 113 10 + 88 26 52 9 0 200 10 + 89 26 35 15 0 211 10 + 90 31 67 3 0 187 10 + 91 15 19 1 0 194 10 + 92 22 22 2 18 48 10 + 93 18 24 22 0 199 10 + 94 26 27 27 0 207 10 + 95 25 24 20 0 205 10 + 96 22 27 11 0 204 10 + 97 25 21 12 0 202 10 + 98 19 21 10 0 198 10 + 99 20 26 9 73 103 10 + 100 18 18 17 165 195 10 diff --git a/jsprit-instances/instances/solomon/R109.txt b/jsprit-instances/instances/solomon/R109.txt new file mode 100644 index 00000000..7a041ffe --- /dev/null +++ b/jsprit-instances/instances/solomon/R109.txt @@ -0,0 +1,110 @@ +R109 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 133 198 10 + 2 35 17 7 22 87 10 + 3 55 45 13 98 143 10 + 4 55 20 19 123 184 10 + 5 15 30 26 20 93 10 + 6 25 30 3 76 131 10 + 7 20 50 5 61 110 10 + 8 10 43 9 75 124 10 + 9 55 60 16 74 129 10 + 10 30 60 16 107 150 10 + 11 20 65 12 42 101 10 + 12 50 35 19 38 97 10 + 13 30 25 23 131 196 10 + 14 15 10 20 32 114 10 + 15 30 5 8 35 96 10 + 16 10 20 19 52 107 10 + 17 5 30 2 124 189 10 + 18 20 40 12 69 114 10 + 19 15 60 17 52 109 10 + 20 45 65 9 105 156 10 + 21 45 20 11 37 96 10 + 22 45 10 18 76 127 10 + 23 55 5 29 43 102 10 + 24 65 35 3 124 190 10 + 25 65 20 6 121 186 10 + 26 45 30 17 112 161 10 + 27 35 40 16 8 75 10 + 28 41 37 16 11 76 10 + 29 64 42 9 37 98 10 + 30 40 60 21 49 102 10 + 31 31 52 27 24 85 10 + 32 35 69 23 116 175 10 + 33 53 52 11 24 92 10 + 34 65 55 14 96 147 10 + 35 63 65 8 116 178 10 + 36 2 60 5 41 112 10 + 37 20 20 8 113 164 10 + 38 5 5 16 60 115 10 + 39 60 12 31 33 110 10 + 40 40 25 9 65 114 10 + 41 42 7 5 72 131 10 + 42 24 12 5 25 91 10 + 43 23 3 7 111 162 10 + 44 11 14 18 45 102 10 + 45 6 38 16 29 99 10 + 46 2 48 1 92 151 10 + 47 8 56 27 34 105 10 + 48 13 52 36 128 192 10 + 49 6 68 30 93 132 10 + 50 47 47 13 102 155 10 + 51 49 58 10 64 121 10 + 52 27 43 9 26 87 10 + 53 37 31 14 75 124 10 + 54 57 29 18 118 171 10 + 55 63 23 2 111 170 10 + 56 53 12 6 106 163 10 + 57 32 12 7 77 134 10 + 58 36 26 18 147 210 10 + 59 21 24 28 17 100 10 + 60 17 34 3 134 199 10 + 61 12 24 13 55 106 10 + 62 24 58 19 30 95 10 + 63 27 69 10 34 103 10 + 64 15 77 9 48 107 10 + 65 62 77 20 49 113 10 + 66 49 73 25 104 159 10 + 67 67 5 25 59 116 10 + 68 56 39 36 117 176 10 + 69 37 47 6 23 86 10 + 70 37 56 5 123 198 10 + 71 57 68 15 54 109 10 + 72 47 16 25 22 96 10 + 73 44 17 9 56 109 10 + 74 46 13 8 123 184 10 + 75 49 11 18 45 102 10 + 76 49 42 13 52 103 10 + 77 53 43 14 136 200 10 + 78 61 52 3 71 130 10 + 79 57 48 23 72 121 10 + 80 56 37 6 135 198 10 + 81 55 54 26 78 119 10 + 82 15 47 16 29 90 10 + 83 14 37 11 21 89 10 + 84 11 31 7 81 130 10 + 85 16 22 41 70 121 10 + 86 4 18 35 74 123 10 + 87 28 18 26 79 116 10 + 88 26 52 9 50 107 10 + 89 26 35 15 139 211 10 + 90 31 67 3 73 126 10 + 91 15 19 1 132 194 10 + 92 22 22 2 18 88 10 + 93 18 24 22 129 199 10 + 94 26 27 27 81 128 10 + 95 25 24 20 14 78 10 + 96 22 27 11 114 165 10 + 97 25 21 12 115 160 10 + 98 19 21 10 32 93 10 + 99 20 26 9 60 115 10 + 100 18 18 17 123 195 10 diff --git a/jsprit-instances/instances/solomon/R110.txt b/jsprit-instances/instances/solomon/R110.txt new file mode 100644 index 00000000..3372cb2d --- /dev/null +++ b/jsprit-instances/instances/solomon/R110.txt @@ -0,0 +1,110 @@ +R110 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 130 201 10 + 2 35 17 7 20 89 10 + 3 55 45 13 106 135 10 + 4 55 20 19 71 195 10 + 5 15 30 26 20 107 10 + 6 25 30 3 54 153 10 + 7 20 50 5 66 105 10 + 8 10 43 9 61 138 10 + 9 55 60 16 53 150 10 + 10 30 60 16 101 156 10 + 11 20 65 12 33 152 10 + 12 50 35 19 38 97 10 + 13 30 25 23 70 208 10 + 14 15 10 20 32 137 10 + 15 30 5 8 30 154 10 + 16 10 20 19 54 105 10 + 17 5 30 2 51 189 10 + 18 20 40 12 77 106 10 + 19 15 60 17 53 108 10 + 20 45 65 9 109 152 10 + 21 45 20 11 37 96 10 + 22 45 10 18 59 144 10 + 23 55 5 29 36 155 10 + 24 65 35 3 118 190 10 + 25 65 20 6 47 186 10 + 26 45 30 17 117 156 10 + 27 35 40 16 5 156 10 + 28 41 37 16 8 79 10 + 29 64 42 9 37 98 10 + 30 40 60 21 28 123 10 + 31 31 52 27 24 85 10 + 32 35 69 23 116 175 10 + 33 53 52 11 24 179 10 + 34 65 55 14 100 143 10 + 35 63 65 8 50 178 10 + 36 2 60 5 41 178 10 + 37 20 20 8 117 160 10 + 38 5 5 16 42 145 10 + 39 60 12 31 33 186 10 + 40 40 25 9 51 128 10 + 41 42 7 5 44 159 10 + 42 24 12 5 25 172 10 + 43 23 3 7 115 158 10 + 44 11 14 18 31 138 10 + 45 6 38 16 29 189 10 + 46 2 48 1 93 150 10 + 47 8 56 27 34 116 10 + 48 13 52 36 125 192 10 + 49 6 68 30 93 132 10 + 50 47 47 13 105 152 10 + 51 49 58 10 66 119 10 + 52 27 43 9 25 88 10 + 53 37 31 14 62 137 10 + 54 57 29 18 121 168 10 + 55 63 23 2 70 189 10 + 56 53 12 6 81 188 10 + 57 32 12 7 78 133 10 + 58 36 26 18 79 210 10 + 59 21 24 28 17 123 10 + 60 17 34 3 130 201 10 + 61 12 24 13 59 102 10 + 62 24 58 19 25 164 10 + 63 27 69 10 34 112 10 + 64 15 77 9 46 165 10 + 65 62 77 20 49 170 10 + 66 49 73 25 77 179 10 + 67 67 5 25 43 150 10 + 68 56 39 36 82 198 10 + 69 37 47 6 12 142 10 + 70 37 56 5 21 198 10 + 71 57 68 15 57 106 10 + 72 47 16 25 22 110 10 + 73 44 17 9 60 105 10 + 74 46 13 8 73 195 10 + 75 49 11 18 46 101 10 + 76 49 42 13 36 119 10 + 77 53 43 14 65 200 10 + 78 61 52 3 43 158 10 + 79 57 48 23 58 135 10 + 80 56 37 6 69 198 10 + 81 55 54 26 87 110 10 + 82 15 47 16 28 91 10 + 83 14 37 11 21 97 10 + 84 11 31 7 68 143 10 + 85 16 22 41 74 117 10 + 86 4 18 35 79 118 10 + 87 28 18 26 84 111 10 + 88 26 52 9 24 133 10 + 89 26 35 15 128 211 10 + 90 31 67 3 76 123 10 + 91 15 19 1 130 194 10 + 92 22 22 2 18 181 10 + 93 18 24 22 41 199 10 + 94 26 27 27 88 121 10 + 95 25 24 20 14 83 10 + 96 22 27 11 119 160 10 + 97 25 21 12 122 153 10 + 98 19 21 10 32 93 10 + 99 20 26 9 38 137 10 + 100 18 18 17 28 195 10 diff --git a/jsprit-instances/instances/solomon/R111.txt b/jsprit-instances/instances/solomon/R111.txt new file mode 100644 index 00000000..ba3b3e31 --- /dev/null +++ b/jsprit-instances/instances/solomon/R111.txt @@ -0,0 +1,110 @@ +R111 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 15 204 10 + 2 35 17 7 18 202 10 + 3 55 45 13 54 187 10 + 4 55 20 19 138 169 10 + 5 15 30 26 20 199 10 + 6 25 30 3 76 131 10 + 7 20 50 5 21 170 10 + 8 10 43 9 87 112 10 + 9 55 60 16 88 115 10 + 10 30 60 16 107 150 10 + 11 20 65 12 57 86 10 + 12 50 35 19 15 192 10 + 13 30 25 23 147 180 10 + 14 15 10 20 32 187 10 + 15 30 5 8 50 81 10 + 16 10 20 19 29 139 10 + 17 5 30 2 124 189 10 + 18 20 40 12 47 136 10 + 19 15 60 17 32 146 10 + 20 45 65 9 79 182 10 + 21 45 20 11 18 195 10 + 22 45 10 18 76 127 10 + 23 55 5 29 58 87 10 + 24 65 35 3 58 190 10 + 25 65 20 6 153 186 10 + 26 45 30 17 58 208 10 + 27 35 40 16 8 75 10 + 28 41 37 16 6 136 10 + 29 64 42 9 29 150 10 + 30 40 60 21 49 102 10 + 31 31 52 27 17 198 10 + 32 35 69 23 67 186 10 + 33 53 52 11 24 92 10 + 34 65 55 14 36 183 10 + 35 63 65 8 116 178 10 + 36 2 60 5 41 112 10 + 37 20 20 8 42 198 10 + 38 5 5 16 74 101 10 + 39 60 12 31 33 110 10 + 40 40 25 9 65 114 10 + 41 42 7 5 72 131 10 + 42 24 12 5 25 91 10 + 43 23 3 7 82 185 10 + 44 11 14 18 59 88 10 + 45 6 38 16 29 99 10 + 46 2 48 1 63 180 10 + 47 8 56 27 34 176 10 + 48 13 52 36 27 192 10 + 49 6 68 30 93 132 10 + 50 47 47 13 41 203 10 + 51 49 58 10 36 149 10 + 52 27 43 9 11 195 10 + 53 37 31 14 87 112 10 + 54 57 29 18 90 197 10 + 55 63 23 2 126 155 10 + 56 53 12 6 106 163 10 + 57 32 12 7 48 163 10 + 58 36 26 18 178 210 10 + 59 21 24 28 17 202 10 + 60 17 34 3 70 201 10 + 61 12 24 13 29 132 10 + 62 24 58 19 46 79 10 + 63 27 69 10 34 172 10 + 64 15 77 9 48 107 10 + 65 62 77 20 49 113 10 + 66 49 73 25 104 159 10 + 67 67 5 25 73 102 10 + 68 56 39 36 117 176 10 + 69 37 47 6 39 70 10 + 70 37 56 5 123 198 10 + 71 57 68 15 39 148 10 + 72 47 16 25 22 197 10 + 73 44 17 9 30 135 10 + 74 46 13 8 138 169 10 + 75 49 11 18 27 192 10 + 76 49 42 13 65 90 10 + 77 53 43 14 168 199 10 + 78 61 52 3 71 130 10 + 79 57 48 23 84 109 10 + 80 56 37 6 135 198 10 + 81 55 54 26 57 140 10 + 82 15 47 16 23 196 10 + 83 14 37 11 21 198 10 + 84 11 31 7 93 118 10 + 85 16 22 41 23 177 10 + 86 4 18 35 49 148 10 + 87 28 18 26 88 107 10 + 88 26 52 9 50 107 10 + 89 26 35 15 68 211 10 + 90 31 67 3 46 153 10 + 91 15 19 1 25 194 10 + 92 22 22 2 18 53 10 + 93 18 24 22 129 199 10 + 94 26 27 27 35 174 10 + 95 25 24 20 14 205 10 + 96 22 27 11 51 204 10 + 97 25 21 12 92 183 10 + 98 19 21 10 21 198 10 + 99 20 26 9 74 101 10 + 100 18 18 17 159 195 10 diff --git a/jsprit-instances/instances/solomon/R112.txt b/jsprit-instances/instances/solomon/R112.txt new file mode 100644 index 00000000..5a10af7f --- /dev/null +++ b/jsprit-instances/instances/solomon/R112.txt @@ -0,0 +1,110 @@ +R112 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 230 0 + 1 41 49 10 73 204 10 + 2 35 17 7 18 147 10 + 3 55 45 13 76 165 10 + 4 55 20 19 73 195 10 + 5 15 30 26 20 167 10 + 6 25 30 3 49 158 10 + 7 20 50 5 36 135 10 + 8 10 43 9 50 149 10 + 9 55 60 16 47 156 10 + 10 30 60 16 85 172 10 + 11 20 65 12 33 152 10 + 12 50 35 19 15 133 10 + 13 30 25 23 79 208 10 + 14 15 10 20 32 187 10 + 15 30 5 8 30 152 10 + 16 10 20 19 29 139 10 + 17 5 30 2 60 189 10 + 18 20 40 12 47 136 10 + 19 15 60 17 32 146 10 + 20 45 65 9 79 182 10 + 21 45 20 11 18 136 10 + 22 45 10 18 50 153 10 + 23 55 5 29 36 155 10 + 24 65 35 3 58 190 10 + 25 65 20 6 56 186 10 + 26 45 30 17 87 186 10 + 27 35 40 16 5 140 10 + 28 41 37 16 6 136 10 + 29 64 42 9 29 150 10 + 30 40 60 21 25 132 10 + 31 31 52 27 17 138 10 + 32 35 69 23 67 186 10 + 33 53 52 11 24 161 10 + 34 65 55 14 70 173 10 + 35 63 65 8 54 178 10 + 36 2 60 5 41 178 10 + 37 20 20 8 87 190 10 + 38 5 5 16 42 153 10 + 39 60 12 31 33 186 10 + 40 40 25 9 40 139 10 + 41 42 7 5 43 160 10 + 42 24 12 5 25 158 10 + 43 23 3 7 82 185 10 + 44 11 14 18 31 144 10 + 45 6 38 16 29 169 10 + 46 2 48 1 63 180 10 + 47 8 56 27 34 176 10 + 48 13 52 36 65 192 10 + 49 6 68 30 73 152 10 + 50 47 47 13 75 182 10 + 51 49 58 10 36 149 10 + 52 27 43 9 11 133 10 + 53 37 31 14 51 148 10 + 54 57 29 18 90 197 10 + 55 63 23 2 69 189 10 + 56 53 12 6 76 190 10 + 57 32 12 7 48 163 10 + 58 36 26 18 84 210 10 + 59 21 24 28 17 183 10 + 60 17 34 3 70 201 10 + 61 12 24 13 29 132 10 + 62 24 58 19 25 154 10 + 63 27 69 10 34 172 10 + 64 15 77 9 46 165 10 + 65 62 77 20 49 170 10 + 66 49 73 25 68 179 10 + 67 67 5 25 43 156 10 + 68 56 39 36 80 198 10 + 69 37 47 6 12 137 10 + 70 37 56 5 48 198 10 + 71 57 68 15 39 148 10 + 72 47 16 25 22 170 10 + 73 44 17 9 30 135 10 + 74 46 13 8 74 195 10 + 75 49 11 18 27 141 10 + 76 49 42 13 27 128 10 + 77 53 43 14 72 200 10 + 78 61 52 3 42 159 10 + 79 57 48 23 47 146 10 + 80 56 37 6 73 198 10 + 81 55 54 26 57 140 10 + 82 15 47 16 23 146 10 + 83 14 37 11 21 157 10 + 84 11 31 7 57 154 10 + 85 16 22 41 44 147 10 + 86 4 18 35 49 148 10 + 87 28 18 26 61 134 10 + 88 26 52 9 21 136 10 + 89 26 35 15 68 211 10 + 90 31 67 3 46 153 10 + 91 15 19 1 70 194 10 + 92 22 22 2 18 159 10 + 93 18 24 22 60 199 10 + 94 26 27 27 58 151 10 + 95 25 24 20 14 143 10 + 96 22 27 11 89 190 10 + 97 25 21 12 92 183 10 + 98 19 21 10 21 142 10 + 99 20 26 9 33 142 10 + 100 18 18 17 51 195 10 diff --git a/jsprit-instances/instances/solomon/R201.txt b/jsprit-instances/instances/solomon/R201.txt new file mode 100644 index 00000000..b0e13e76 --- /dev/null +++ b/jsprit-instances/instances/solomon/R201.txt @@ -0,0 +1,110 @@ +R201 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 707 848 10 + 2 35 17 7 143 282 10 + 3 55 45 13 527 584 10 + 4 55 20 19 678 801 10 + 5 15 30 26 34 209 10 + 6 25 30 3 415 514 10 + 7 20 50 5 331 410 10 + 8 10 43 9 404 481 10 + 9 55 60 16 400 497 10 + 10 30 60 16 577 632 10 + 11 20 65 12 206 325 10 + 12 50 35 19 228 345 10 + 13 30 25 23 690 827 10 + 14 15 10 20 32 243 10 + 15 30 5 8 175 300 10 + 16 10 20 19 272 373 10 + 17 5 30 2 733 870 10 + 18 20 40 12 377 434 10 + 19 15 60 17 269 378 10 + 20 45 65 9 581 666 10 + 21 45 20 11 214 331 10 + 22 45 10 18 409 494 10 + 23 55 5 29 206 325 10 + 24 65 35 3 704 847 10 + 25 65 20 6 817 956 10 + 26 45 30 17 588 667 10 + 27 35 40 16 104 255 10 + 28 41 37 16 114 255 10 + 29 64 42 9 190 313 10 + 30 40 60 21 259 354 10 + 31 31 52 27 152 275 10 + 32 35 69 23 660 777 10 + 33 53 52 11 45 200 10 + 34 65 55 14 529 614 10 + 35 63 65 8 686 813 10 + 36 2 60 5 41 208 10 + 37 20 20 8 606 693 10 + 38 5 5 16 302 405 10 + 39 60 12 31 33 224 10 + 40 40 25 9 360 437 10 + 41 42 7 5 396 511 10 + 42 24 12 5 25 172 10 + 43 23 3 7 620 705 10 + 44 11 14 18 233 340 10 + 45 6 38 16 29 189 10 + 46 2 48 1 515 628 10 + 47 8 56 27 85 250 10 + 48 13 52 36 773 906 10 + 49 6 68 30 501 540 10 + 50 47 47 13 547 642 10 + 51 49 58 10 348 453 10 + 52 27 43 9 174 299 10 + 53 37 31 14 414 489 10 + 54 57 29 18 641 734 10 + 55 63 23 2 620 739 10 + 56 53 12 6 585 692 10 + 57 32 12 7 421 530 10 + 58 36 26 18 849 980 10 + 59 21 24 28 17 229 10 + 60 17 34 3 721 862 10 + 61 12 24 13 290 377 10 + 62 24 58 19 163 302 10 + 63 27 69 10 34 191 10 + 64 15 77 9 214 333 10 + 65 62 77 20 49 188 10 + 66 49 73 25 592 693 10 + 67 67 5 25 294 401 10 + 68 56 39 36 637 752 10 + 69 37 47 6 162 293 10 + 70 37 56 5 788 968 10 + 71 57 68 15 268 367 10 + 72 47 16 25 31 208 10 + 73 44 17 9 308 399 10 + 74 46 13 8 681 802 10 + 75 49 11 18 236 345 10 + 76 49 42 13 290 373 10 + 77 53 43 14 817 952 10 + 78 61 52 3 384 499 10 + 79 57 48 23 388 465 10 + 80 56 37 6 839 968 10 + 81 55 54 26 411 456 10 + 82 15 47 16 162 289 10 + 83 14 37 11 96 249 10 + 84 11 31 7 436 511 10 + 85 16 22 41 376 461 10 + 86 4 18 35 388 465 10 + 87 28 18 26 420 447 10 + 88 26 52 9 279 388 10 + 89 26 35 15 755 920 10 + 90 31 67 3 392 487 10 + 91 15 19 1 739 866 10 + 92 22 22 2 18 181 10 + 93 18 24 22 811 969 10 + 94 26 27 27 436 503 10 + 95 25 24 20 92 231 10 + 96 22 27 11 607 690 10 + 97 25 21 12 612 673 10 + 98 19 21 10 183 306 10 + 99 20 26 9 333 432 10 + 100 18 18 17 798 965 10 diff --git a/jsprit-instances/instances/solomon/R202.txt b/jsprit-instances/instances/solomon/R202.txt new file mode 100644 index 00000000..d70a221b --- /dev/null +++ b/jsprit-instances/instances/solomon/R202.txt @@ -0,0 +1,110 @@ +R202 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 678 801 10 + 5 15 30 26 0 969 10 + 6 25 30 3 415 514 10 + 7 20 50 5 0 968 10 + 8 10 43 9 404 481 10 + 9 55 60 16 400 497 10 + 10 30 60 16 577 632 10 + 11 20 65 12 206 325 10 + 12 50 35 19 0 975 10 + 13 30 25 23 690 827 10 + 14 15 10 20 32 243 10 + 15 30 5 8 175 300 10 + 16 10 20 19 272 373 10 + 17 5 30 2 733 870 10 + 18 20 40 12 377 434 10 + 19 15 60 17 269 378 10 + 20 45 65 9 581 666 10 + 21 45 20 11 0 971 10 + 22 45 10 18 409 494 10 + 23 55 5 29 206 325 10 + 24 65 35 3 704 847 10 + 25 65 20 6 817 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 104 255 10 + 28 41 37 16 114 255 10 + 29 64 42 9 190 313 10 + 30 40 60 21 259 354 10 + 31 31 52 27 0 972 10 + 32 35 69 23 660 777 10 + 33 53 52 11 45 200 10 + 34 65 55 14 0 953 10 + 35 63 65 8 686 813 10 + 36 2 60 5 41 208 10 + 37 20 20 8 0 968 10 + 38 5 5 16 302 405 10 + 39 60 12 31 33 224 10 + 40 40 25 9 360 437 10 + 41 42 7 5 396 511 10 + 42 24 12 5 25 172 10 + 43 23 3 7 620 705 10 + 44 11 14 18 233 340 10 + 45 6 38 16 29 189 10 + 46 2 48 1 515 628 10 + 47 8 56 27 85 250 10 + 48 13 52 36 0 962 10 + 49 6 68 30 501 540 10 + 50 47 47 13 0 973 10 + 51 49 58 10 348 453 10 + 52 27 43 9 0 978 10 + 53 37 31 14 414 489 10 + 54 57 29 18 641 734 10 + 55 63 23 2 620 739 10 + 56 53 12 6 585 692 10 + 57 32 12 7 421 530 10 + 58 36 26 18 849 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 721 862 10 + 61 12 24 13 290 377 10 + 62 24 58 19 163 302 10 + 63 27 69 10 34 191 10 + 64 15 77 9 214 333 10 + 65 62 77 20 49 188 10 + 66 49 73 25 592 693 10 + 67 67 5 25 294 401 10 + 68 56 39 36 637 752 10 + 69 37 47 6 162 293 10 + 70 37 56 5 788 968 10 + 71 57 68 15 268 367 10 + 72 47 16 25 0 967 10 + 73 44 17 9 308 399 10 + 74 46 13 8 681 802 10 + 75 49 11 18 0 962 10 + 76 49 42 13 290 373 10 + 77 53 43 14 817 952 10 + 78 61 52 3 384 499 10 + 79 57 48 23 388 465 10 + 80 56 37 6 839 968 10 + 81 55 54 26 411 456 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 436 511 10 + 85 16 22 41 0 966 10 + 86 4 18 35 388 465 10 + 87 28 18 26 420 447 10 + 88 26 52 9 279 388 10 + 89 26 35 15 755 920 10 + 90 31 67 3 392 487 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 181 10 + 93 18 24 22 811 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 612 673 10 + 98 19 21 10 0 968 10 + 99 20 26 9 333 432 10 + 100 18 18 17 798 965 10 diff --git a/jsprit-instances/instances/solomon/R203.txt b/jsprit-instances/instances/solomon/R203.txt new file mode 100644 index 00000000..401787b6 --- /dev/null +++ b/jsprit-instances/instances/solomon/R203.txt @@ -0,0 +1,110 @@ +R203 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 678 801 10 + 5 15 30 26 0 969 10 + 6 25 30 3 415 514 10 + 7 20 50 5 0 968 10 + 8 10 43 9 404 481 10 + 9 55 60 16 400 497 10 + 10 30 60 16 577 632 10 + 11 20 65 12 206 325 10 + 12 50 35 19 0 975 10 + 13 30 25 23 690 827 10 + 14 15 10 20 0 957 10 + 15 30 5 8 175 300 10 + 16 10 20 19 0 960 10 + 17 5 30 2 733 870 10 + 18 20 40 12 0 974 10 + 19 15 60 17 0 957 10 + 20 45 65 9 0 958 10 + 21 45 20 11 0 971 10 + 22 45 10 18 409 494 10 + 23 55 5 29 206 325 10 + 24 65 35 3 0 960 10 + 25 65 20 6 817 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 104 255 10 + 28 41 37 16 0 983 10 + 29 64 42 9 0 960 10 + 30 40 60 21 259 354 10 + 31 31 52 27 0 972 10 + 32 35 69 23 0 956 10 + 33 53 52 11 45 200 10 + 34 65 55 14 0 953 10 + 35 63 65 8 686 813 10 + 36 2 60 5 41 208 10 + 37 20 20 8 0 968 10 + 38 5 5 16 302 405 10 + 39 60 12 31 33 224 10 + 40 40 25 9 360 437 10 + 41 42 7 5 396 511 10 + 42 24 12 5 25 172 10 + 43 23 3 7 0 955 10 + 44 11 14 18 233 340 10 + 45 6 38 16 29 189 10 + 46 2 48 1 0 954 10 + 47 8 56 27 0 955 10 + 48 13 52 36 0 962 10 + 49 6 68 30 501 540 10 + 50 47 47 13 0 973 10 + 51 49 58 10 0 963 10 + 52 27 43 9 0 978 10 + 53 37 31 14 414 489 10 + 54 57 29 18 0 967 10 + 55 63 23 2 620 739 10 + 56 53 12 6 585 692 10 + 57 32 12 7 0 966 10 + 58 36 26 18 849 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 0 971 10 + 61 12 24 13 0 964 10 + 62 24 58 19 163 302 10 + 63 27 69 10 0 955 10 + 64 15 77 9 214 333 10 + 65 62 77 20 49 188 10 + 66 49 73 25 592 693 10 + 67 67 5 25 294 401 10 + 68 56 39 36 637 752 10 + 69 37 47 6 162 293 10 + 70 37 56 5 788 968 10 + 71 57 68 15 0 950 10 + 72 47 16 25 0 967 10 + 73 44 17 9 0 969 10 + 74 46 13 8 681 802 10 + 75 49 11 18 0 962 10 + 76 49 42 13 290 373 10 + 77 53 43 14 817 952 10 + 78 61 52 3 384 499 10 + 79 57 48 23 388 465 10 + 80 56 37 6 839 968 10 + 81 55 54 26 0 962 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 436 511 10 + 85 16 22 41 0 966 10 + 86 4 18 35 0 954 10 + 87 28 18 26 420 447 10 + 88 26 52 9 279 388 10 + 89 26 35 15 0 981 10 + 90 31 67 3 0 957 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 181 10 + 93 18 24 22 811 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 0 972 10 + 98 19 21 10 0 968 10 + 99 20 26 9 333 432 10 + 100 18 18 17 798 965 10 diff --git a/jsprit-instances/instances/solomon/R204.txt b/jsprit-instances/instances/solomon/R204.txt new file mode 100644 index 00000000..40b8e284 --- /dev/null +++ b/jsprit-instances/instances/solomon/R204.txt @@ -0,0 +1,110 @@ +R204 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 678 801 10 + 5 15 30 26 0 969 10 + 6 25 30 3 0 978 10 + 7 20 50 5 0 968 10 + 8 10 43 9 404 481 10 + 9 55 60 16 400 497 10 + 10 30 60 16 0 964 10 + 11 20 65 12 206 325 10 + 12 50 35 19 0 975 10 + 13 30 25 23 690 827 10 + 14 15 10 20 0 957 10 + 15 30 5 8 175 300 10 + 16 10 20 19 0 960 10 + 17 5 30 2 0 959 10 + 18 20 40 12 0 974 10 + 19 15 60 17 0 957 10 + 20 45 65 9 0 958 10 + 21 45 20 11 0 971 10 + 22 45 10 18 0 963 10 + 23 55 5 29 206 325 10 + 24 65 35 3 0 960 10 + 25 65 20 6 817 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 0 985 10 + 28 41 37 16 0 983 10 + 29 64 42 9 0 960 10 + 30 40 60 21 0 964 10 + 31 31 52 27 0 972 10 + 32 35 69 23 0 956 10 + 33 53 52 11 0 965 10 + 34 65 55 14 0 953 10 + 35 63 65 8 0 948 10 + 36 2 60 5 0 948 10 + 37 20 20 8 0 968 10 + 38 5 5 16 302 405 10 + 39 60 12 31 0 956 10 + 40 40 25 9 0 978 10 + 41 42 7 5 0 961 10 + 42 24 12 5 0 964 10 + 43 23 3 7 0 955 10 + 44 11 14 18 233 340 10 + 45 6 38 16 0 960 10 + 46 2 48 1 0 954 10 + 47 8 56 27 0 955 10 + 48 13 52 36 0 962 10 + 49 6 68 30 0 946 10 + 50 47 47 13 0 973 10 + 51 49 58 10 0 963 10 + 52 27 43 9 0 978 10 + 53 37 31 14 414 489 10 + 54 57 29 18 0 967 10 + 55 63 23 2 620 739 10 + 56 53 12 6 0 960 10 + 57 32 12 7 0 966 10 + 58 36 26 18 849 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 0 971 10 + 61 12 24 13 0 964 10 + 62 24 58 19 163 302 10 + 63 27 69 10 0 955 10 + 64 15 77 9 0 943 10 + 65 62 77 20 0 940 10 + 66 49 73 25 0 949 10 + 67 67 5 25 294 401 10 + 68 56 39 36 0 968 10 + 69 37 47 6 162 293 10 + 70 37 56 5 0 968 10 + 71 57 68 15 0 950 10 + 72 47 16 25 0 967 10 + 73 44 17 9 0 969 10 + 74 46 13 8 681 802 10 + 75 49 11 18 0 962 10 + 76 49 42 13 290 373 10 + 77 53 43 14 817 952 10 + 78 61 52 3 0 958 10 + 79 57 48 23 388 465 10 + 80 56 37 6 0 968 10 + 81 55 54 26 0 962 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 436 511 10 + 85 16 22 41 0 966 10 + 86 4 18 35 0 954 10 + 87 28 18 26 420 447 10 + 88 26 52 9 0 970 10 + 89 26 35 15 0 981 10 + 90 31 67 3 0 957 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 181 10 + 93 18 24 22 0 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 0 972 10 + 98 19 21 10 0 968 10 + 99 20 26 9 333 432 10 + 100 18 18 17 798 965 10 diff --git a/jsprit-instances/instances/solomon/R205.txt b/jsprit-instances/instances/solomon/R205.txt new file mode 100644 index 00000000..af54fada --- /dev/null +++ b/jsprit-instances/instances/solomon/R205.txt @@ -0,0 +1,110 @@ +R205 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 658 898 10 + 2 35 17 7 93 333 10 + 3 55 45 13 436 676 10 + 4 55 20 19 620 860 10 + 5 15 30 26 20 260 10 + 6 25 30 3 345 585 10 + 7 20 50 5 251 491 10 + 8 10 43 9 323 563 10 + 9 55 60 16 329 569 10 + 10 30 60 16 485 725 10 + 11 20 65 12 146 386 10 + 12 50 35 19 167 407 10 + 13 30 25 23 639 879 10 + 14 15 10 20 32 272 10 + 15 30 5 8 118 358 10 + 16 10 20 19 203 443 10 + 17 5 30 2 682 922 10 + 18 20 40 12 286 526 10 + 19 15 60 17 204 444 10 + 20 45 65 9 504 744 10 + 21 45 20 11 153 393 10 + 22 45 10 18 332 572 10 + 23 55 5 29 146 386 10 + 24 65 35 3 656 896 10 + 25 65 20 6 716 956 10 + 26 45 30 17 508 748 10 + 27 35 40 16 60 300 10 + 28 41 37 16 65 305 10 + 29 64 42 9 132 372 10 + 30 40 60 21 187 427 10 + 31 31 52 27 94 334 10 + 32 35 69 23 599 839 10 + 33 53 52 11 24 264 10 + 34 65 55 14 452 692 10 + 35 63 65 8 630 870 10 + 36 2 60 5 41 281 10 + 37 20 20 8 530 770 10 + 38 5 5 16 234 474 10 + 39 60 12 31 33 273 10 + 40 40 25 9 279 519 10 + 41 42 7 5 334 574 10 + 42 24 12 5 25 265 10 + 43 23 3 7 543 783 10 + 44 11 14 18 167 407 10 + 45 6 38 16 29 269 10 + 46 2 48 1 452 692 10 + 47 8 56 27 48 288 10 + 48 13 52 36 720 960 10 + 49 6 68 30 401 641 10 + 50 47 47 13 475 715 10 + 51 49 58 10 281 521 10 + 52 27 43 9 117 357 10 + 53 37 31 14 332 572 10 + 54 57 29 18 568 808 10 + 55 63 23 2 560 800 10 + 56 53 12 6 519 759 10 + 57 32 12 7 356 596 10 + 58 36 26 18 740 980 10 + 59 21 24 28 17 257 10 + 60 17 34 3 672 912 10 + 61 12 24 13 214 454 10 + 62 24 58 19 113 353 10 + 63 27 69 10 34 274 10 + 64 15 77 9 154 394 10 + 65 62 77 20 49 289 10 + 66 49 73 25 523 763 10 + 67 67 5 25 228 468 10 + 68 56 39 36 575 815 10 + 69 37 47 6 108 348 10 + 70 37 56 5 728 968 10 + 71 57 68 15 198 438 10 + 72 47 16 25 22 262 10 + 73 44 17 9 234 474 10 + 74 46 13 8 622 862 10 + 75 49 11 18 171 411 10 + 76 49 42 13 212 452 10 + 77 53 43 14 730 970 10 + 78 61 52 3 322 562 10 + 79 57 48 23 307 547 10 + 80 56 37 6 728 968 10 + 81 55 54 26 314 554 10 + 82 15 47 16 106 346 10 + 83 14 37 11 53 293 10 + 84 11 31 7 354 594 10 + 85 16 22 41 299 539 10 + 86 4 18 35 307 547 10 + 87 28 18 26 314 554 10 + 88 26 52 9 214 454 10 + 89 26 35 15 718 958 10 + 90 31 67 3 320 560 10 + 91 15 19 1 683 923 10 + 92 22 22 2 18 258 10 + 93 18 24 22 729 969 10 + 94 26 27 27 350 590 10 + 95 25 24 20 42 282 10 + 96 22 27 11 529 769 10 + 97 25 21 12 523 763 10 + 98 19 21 10 125 365 10 + 99 20 26 9 263 503 10 + 100 18 18 17 725 965 10 diff --git a/jsprit-instances/instances/solomon/R206.txt b/jsprit-instances/instances/solomon/R206.txt new file mode 100644 index 00000000..6e5477a2 --- /dev/null +++ b/jsprit-instances/instances/solomon/R206.txt @@ -0,0 +1,110 @@ +R206 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 620 860 10 + 5 15 30 26 0 969 10 + 6 25 30 3 345 585 10 + 7 20 50 5 0 968 10 + 8 10 43 9 323 563 10 + 9 55 60 16 329 569 10 + 10 30 60 16 485 725 10 + 11 20 65 12 146 386 10 + 12 50 35 19 0 975 10 + 13 30 25 23 639 879 10 + 14 15 10 20 32 272 10 + 15 30 5 8 118 358 10 + 16 10 20 19 203 443 10 + 17 5 30 2 682 922 10 + 18 20 40 12 286 526 10 + 19 15 60 17 204 444 10 + 20 45 65 9 504 744 10 + 21 45 20 11 0 971 10 + 22 45 10 18 332 572 10 + 23 55 5 29 146 386 10 + 24 65 35 3 656 896 10 + 25 65 20 6 716 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 60 300 10 + 28 41 37 16 65 305 10 + 29 64 42 9 132 372 10 + 30 40 60 21 187 427 10 + 31 31 52 27 0 972 10 + 32 35 69 23 599 839 10 + 33 53 52 11 24 264 10 + 34 65 55 14 0 953 10 + 35 63 65 8 630 870 10 + 36 2 60 5 41 281 10 + 37 20 20 8 0 968 10 + 38 5 5 16 234 474 10 + 39 60 12 31 33 273 10 + 40 40 25 9 279 519 10 + 41 42 7 5 334 574 10 + 42 24 12 5 25 265 10 + 43 23 3 7 543 783 10 + 44 11 14 18 167 407 10 + 45 6 38 16 29 269 10 + 46 2 48 1 452 692 10 + 47 8 56 27 48 288 10 + 48 13 52 36 0 962 10 + 49 6 68 30 401 641 10 + 50 47 47 13 0 973 10 + 51 49 58 10 281 521 10 + 52 27 43 9 0 978 10 + 53 37 31 14 332 572 10 + 54 57 29 18 568 808 10 + 55 63 23 2 560 800 10 + 56 53 12 6 519 759 10 + 57 32 12 7 356 596 10 + 58 36 26 18 740 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 672 912 10 + 61 12 24 13 214 454 10 + 62 24 58 19 113 353 10 + 63 27 69 10 34 274 10 + 64 15 77 9 154 394 10 + 65 62 77 20 49 289 10 + 66 49 73 25 523 763 10 + 67 67 5 25 228 468 10 + 68 56 39 36 575 815 10 + 69 37 47 6 108 348 10 + 70 37 56 5 728 968 10 + 71 57 68 15 198 438 10 + 72 47 16 25 0 967 10 + 73 44 17 9 234 474 10 + 74 46 13 8 622 862 10 + 75 49 11 18 0 962 10 + 76 49 42 13 212 452 10 + 77 53 43 14 730 970 10 + 78 61 52 3 322 562 10 + 79 57 48 23 307 547 10 + 80 56 37 6 728 968 10 + 81 55 54 26 314 554 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 354 594 10 + 85 16 22 41 0 966 10 + 86 4 18 35 307 547 10 + 87 28 18 26 314 554 10 + 88 26 52 9 214 454 10 + 89 26 35 15 718 958 10 + 90 31 67 3 320 560 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 258 10 + 93 18 24 22 729 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 523 763 10 + 98 19 21 10 0 968 10 + 99 20 26 9 263 503 10 + 100 18 18 17 725 965 10 diff --git a/jsprit-instances/instances/solomon/R207.txt b/jsprit-instances/instances/solomon/R207.txt new file mode 100644 index 00000000..fcbfd15f --- /dev/null +++ b/jsprit-instances/instances/solomon/R207.txt @@ -0,0 +1,110 @@ +R207 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 620 860 10 + 5 15 30 26 0 969 10 + 6 25 30 3 345 585 10 + 7 20 50 5 0 968 10 + 8 10 43 9 323 563 10 + 9 55 60 16 329 569 10 + 10 30 60 16 485 725 10 + 11 20 65 12 146 386 10 + 12 50 35 19 0 975 10 + 13 30 25 23 639 879 10 + 14 15 10 20 0 957 10 + 15 30 5 8 118 358 10 + 16 10 20 19 0 960 10 + 17 5 30 2 682 922 10 + 18 20 40 12 0 974 10 + 19 15 60 17 0 957 10 + 20 45 65 9 0 958 10 + 21 45 20 11 0 971 10 + 22 45 10 18 332 572 10 + 23 55 5 29 146 386 10 + 24 65 35 3 0 960 10 + 25 65 20 6 716 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 60 300 10 + 28 41 37 16 0 983 10 + 29 64 42 9 0 960 10 + 30 40 60 21 187 427 10 + 31 31 52 27 0 972 10 + 32 35 69 23 0 956 10 + 33 53 52 11 24 264 10 + 34 65 55 14 0 953 10 + 35 63 65 8 630 870 10 + 36 2 60 5 41 281 10 + 37 20 20 8 0 968 10 + 38 5 5 16 234 474 10 + 39 60 12 31 33 273 10 + 40 40 25 9 279 519 10 + 41 42 7 5 334 574 10 + 42 24 12 5 25 265 10 + 43 23 3 7 0 955 10 + 44 11 14 18 167 407 10 + 45 6 38 16 29 269 10 + 46 2 48 1 0 954 10 + 47 8 56 27 0 955 10 + 48 13 52 36 0 962 10 + 49 6 68 30 401 641 10 + 50 47 47 13 0 973 10 + 51 49 58 10 0 963 10 + 52 27 43 9 0 978 10 + 53 37 31 14 332 572 10 + 54 57 29 18 0 967 10 + 55 63 23 2 560 800 10 + 56 53 12 6 519 759 10 + 57 32 12 7 0 966 10 + 58 36 26 18 740 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 0 971 10 + 61 12 24 13 0 964 10 + 62 24 58 19 113 353 10 + 63 27 69 10 0 955 10 + 64 15 77 9 154 394 10 + 65 62 77 20 49 289 10 + 66 49 73 25 523 763 10 + 67 67 5 25 228 468 10 + 68 56 39 36 575 815 10 + 69 37 47 6 108 348 10 + 70 37 56 5 728 968 10 + 71 57 68 15 0 950 10 + 72 47 16 25 0 967 10 + 73 44 17 9 0 969 10 + 74 46 13 8 622 862 10 + 75 49 11 18 0 962 10 + 76 49 42 13 212 452 10 + 77 53 43 14 730 970 10 + 78 61 52 3 322 562 10 + 79 57 48 23 307 547 10 + 80 56 37 6 728 968 10 + 81 55 54 26 0 962 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 354 594 10 + 85 16 22 41 0 966 10 + 86 4 18 35 0 954 10 + 87 28 18 26 314 554 10 + 88 26 52 9 214 454 10 + 89 26 35 15 0 981 10 + 90 31 67 3 0 957 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 258 10 + 93 18 24 22 729 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 0 972 10 + 98 19 21 10 0 968 10 + 99 20 26 9 263 503 10 + 100 18 18 17 725 965 10 diff --git a/jsprit-instances/instances/solomon/R208.txt b/jsprit-instances/instances/solomon/R208.txt new file mode 100644 index 00000000..e51dc7fe --- /dev/null +++ b/jsprit-instances/instances/solomon/R208.txt @@ -0,0 +1,110 @@ +R208 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 0 974 10 + 2 35 17 7 0 972 10 + 3 55 45 13 0 967 10 + 4 55 20 19 620 860 10 + 5 15 30 26 0 969 10 + 6 25 30 3 0 978 10 + 7 20 50 5 0 968 10 + 8 10 43 9 323 563 10 + 9 55 60 16 329 569 10 + 10 30 60 16 0 964 10 + 11 20 65 12 146 386 10 + 12 50 35 19 0 975 10 + 13 30 25 23 639 879 10 + 14 15 10 20 0 957 10 + 15 30 5 8 118 358 10 + 16 10 20 19 0 960 10 + 17 5 30 2 0 959 10 + 18 20 40 12 0 974 10 + 19 15 60 17 0 957 10 + 20 45 65 9 0 958 10 + 21 45 20 11 0 971 10 + 22 45 10 18 0 963 10 + 23 55 5 29 146 386 10 + 24 65 35 3 0 960 10 + 25 65 20 6 716 956 10 + 26 45 30 17 0 978 10 + 27 35 40 16 0 985 10 + 28 41 37 16 0 983 10 + 29 64 42 9 0 960 10 + 30 40 60 21 0 964 10 + 31 31 52 27 0 972 10 + 32 35 69 23 0 956 10 + 33 53 52 11 0 965 10 + 34 65 55 14 0 953 10 + 35 63 65 8 0 948 10 + 36 2 60 5 0 948 10 + 37 20 20 8 0 968 10 + 38 5 5 16 234 474 10 + 39 60 12 31 0 956 10 + 40 40 25 9 0 978 10 + 41 42 7 5 0 961 10 + 42 24 12 5 0 964 10 + 43 23 3 7 0 955 10 + 44 11 14 18 167 407 10 + 45 6 38 16 0 960 10 + 46 2 48 1 0 954 10 + 47 8 56 27 0 955 10 + 48 13 52 36 0 962 10 + 49 6 68 30 0 946 10 + 50 47 47 13 0 973 10 + 51 49 58 10 0 963 10 + 52 27 43 9 0 978 10 + 53 37 31 14 332 572 10 + 54 57 29 18 0 967 10 + 55 63 23 2 560 800 10 + 56 53 12 6 0 960 10 + 57 32 12 7 0 966 10 + 58 36 26 18 740 980 10 + 59 21 24 28 0 972 10 + 60 17 34 3 0 971 10 + 61 12 24 13 0 964 10 + 62 24 58 19 113 353 10 + 63 27 69 10 0 955 10 + 64 15 77 9 0 943 10 + 65 62 77 20 0 940 10 + 66 49 73 25 0 949 10 + 67 67 5 25 228 468 10 + 68 56 39 36 0 968 10 + 69 37 47 6 108 348 10 + 70 37 56 5 0 968 10 + 71 57 68 15 0 950 10 + 72 47 16 25 0 967 10 + 73 44 17 9 0 969 10 + 74 46 13 8 622 862 10 + 75 49 11 18 0 962 10 + 76 49 42 13 212 452 10 + 77 53 43 14 730 970 10 + 78 61 52 3 0 958 10 + 79 57 48 23 307 547 10 + 80 56 37 6 0 968 10 + 81 55 54 26 0 962 10 + 82 15 47 16 0 966 10 + 83 14 37 11 0 968 10 + 84 11 31 7 354 594 10 + 85 16 22 41 0 966 10 + 86 4 18 35 0 954 10 + 87 28 18 26 314 554 10 + 88 26 52 9 0 970 10 + 89 26 35 15 0 981 10 + 90 31 67 3 0 957 10 + 91 15 19 1 0 964 10 + 92 22 22 2 18 258 10 + 93 18 24 22 0 969 10 + 94 26 27 27 0 977 10 + 95 25 24 20 0 975 10 + 96 22 27 11 0 974 10 + 97 25 21 12 0 972 10 + 98 19 21 10 0 968 10 + 99 20 26 9 263 503 10 + 100 18 18 17 725 965 10 diff --git a/jsprit-instances/instances/solomon/R209.txt b/jsprit-instances/instances/solomon/R209.txt new file mode 100644 index 00000000..8b8a9aed --- /dev/null +++ b/jsprit-instances/instances/solomon/R209.txt @@ -0,0 +1,110 @@ +R209 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 636 919 10 + 2 35 17 7 74 351 10 + 3 55 45 13 498 613 10 + 4 55 20 19 470 965 10 + 5 15 30 26 20 370 10 + 6 25 30 3 266 663 10 + 7 20 50 5 292 449 10 + 8 10 43 9 288 597 10 + 9 55 60 16 254 643 10 + 10 30 60 16 496 713 10 + 11 20 65 12 33 510 10 + 12 50 35 19 170 403 10 + 13 30 25 23 426 978 10 + 14 15 10 20 32 454 10 + 15 30 5 8 30 529 10 + 16 10 20 19 222 423 10 + 17 5 30 2 409 959 10 + 18 20 40 12 349 462 10 + 19 15 60 17 215 432 10 + 20 45 65 9 538 709 10 + 21 45 20 11 156 389 10 + 22 45 10 18 280 623 10 + 23 55 5 29 36 513 10 + 24 65 35 3 633 918 10 + 25 65 20 6 400 956 10 + 26 45 30 17 548 707 10 + 27 35 40 16 5 612 10 + 28 41 37 16 44 325 10 + 29 64 42 9 129 374 10 + 30 40 60 21 115 498 10 + 31 31 52 27 91 336 10 + 32 35 69 23 602 835 10 + 33 53 52 11 24 646 10 + 34 65 55 14 487 656 10 + 35 63 65 8 439 948 10 + 36 2 60 5 41 710 10 + 37 20 20 8 563 736 10 + 38 5 5 16 147 560 10 + 39 60 12 31 33 797 10 + 40 40 25 9 243 554 10 + 41 42 7 5 225 682 10 + 42 24 12 5 25 616 10 + 43 23 3 7 578 747 10 + 44 11 14 18 72 501 10 + 45 6 38 16 29 669 10 + 46 2 48 1 458 685 10 + 47 8 56 27 34 362 10 + 48 13 52 36 694 962 10 + 49 6 68 30 444 597 10 + 50 47 47 13 499 690 10 + 51 49 58 10 296 505 10 + 52 27 43 9 111 362 10 + 53 37 31 14 301 602 10 + 54 57 29 18 595 780 10 + 55 63 23 2 442 917 10 + 56 53 12 6 426 851 10 + 57 32 12 7 366 585 10 + 58 36 26 18 458 980 10 + 59 21 24 28 17 441 10 + 60 17 34 3 651 932 10 + 61 12 24 13 246 421 10 + 62 24 58 19 25 583 10 + 63 27 69 10 34 348 10 + 64 15 77 9 46 523 10 + 65 62 77 20 49 608 10 + 66 49 73 25 440 845 10 + 67 67 5 25 132 563 10 + 68 56 39 36 464 925 10 + 69 37 47 6 12 535 10 + 70 37 56 5 249 968 10 + 71 57 68 15 218 417 10 + 72 47 16 25 22 377 10 + 73 44 17 9 263 444 10 + 74 46 13 8 479 965 10 + 75 49 11 18 182 399 10 + 76 49 42 13 166 497 10 + 77 53 43 14 430 970 10 + 78 61 52 3 212 671 10 + 79 57 48 23 273 580 10 + 80 56 37 6 452 968 10 + 81 55 54 26 388 479 10 + 82 15 47 16 99 352 10 + 83 14 37 11 21 328 10 + 84 11 31 7 323 624 10 + 85 16 22 41 333 504 10 + 86 4 18 35 350 503 10 + 87 28 18 26 380 487 10 + 88 26 52 9 114 553 10 + 89 26 35 15 649 981 10 + 90 31 67 3 345 534 10 + 91 15 19 1 675 930 10 + 92 22 22 2 18 673 10 + 93 18 24 22 339 969 10 + 94 26 27 27 403 536 10 + 95 25 24 20 22 301 10 + 96 22 27 11 565 732 10 + 97 25 21 12 582 703 10 + 98 19 21 10 122 367 10 + 99 20 26 9 185 580 10 + 100 18 18 17 297 965 10 diff --git a/jsprit-instances/instances/solomon/R210.txt b/jsprit-instances/instances/solomon/R210.txt new file mode 100644 index 00000000..29ca3dee --- /dev/null +++ b/jsprit-instances/instances/solomon/R210.txt @@ -0,0 +1,110 @@ +R210 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 190 974 10 + 2 35 17 7 18 792 10 + 3 55 45 13 289 822 10 + 4 55 20 19 679 800 10 + 5 15 30 26 20 906 10 + 6 25 30 3 355 574 10 + 7 20 50 5 72 669 10 + 8 10 43 9 393 492 10 + 9 55 60 16 394 503 10 + 10 30 60 16 517 692 10 + 11 20 65 12 206 325 10 + 12 50 35 19 15 725 10 + 13 30 25 23 694 823 10 + 14 15 10 20 32 694 10 + 15 30 5 8 176 299 10 + 16 10 20 19 102 543 10 + 17 5 30 2 673 930 10 + 18 20 40 12 229 582 10 + 19 15 60 17 95 552 10 + 20 45 65 9 418 829 10 + 21 45 20 11 18 727 10 + 22 45 10 18 349 554 10 + 23 55 5 29 206 325 10 + 24 65 35 3 435 960 10 + 25 65 20 6 826 956 10 + 26 45 30 17 328 927 10 + 27 35 40 16 44 315 10 + 28 41 37 16 6 526 10 + 29 64 42 9 29 513 10 + 30 40 60 21 199 414 10 + 31 31 52 27 17 744 10 + 32 35 69 23 482 955 10 + 33 53 52 11 24 299 10 + 34 65 55 14 265 878 10 + 35 63 65 8 626 873 10 + 36 2 60 5 41 328 10 + 37 20 20 8 339 960 10 + 38 5 5 16 298 409 10 + 39 60 12 31 33 344 10 + 40 40 25 9 300 497 10 + 41 42 7 5 336 571 10 + 42 24 12 5 25 292 10 + 43 23 3 7 458 867 10 + 44 11 14 18 230 343 10 + 45 6 38 16 29 309 10 + 46 2 48 1 338 805 10 + 47 8 56 27 34 602 10 + 48 13 52 36 200 962 10 + 49 6 68 30 441 600 10 + 50 47 47 13 272 917 10 + 51 49 58 10 176 625 10 + 52 27 43 9 11 748 10 + 53 37 31 14 403 500 10 + 54 57 29 18 475 900 10 + 55 63 23 2 620 739 10 + 56 53 12 6 525 752 10 + 57 32 12 7 246 705 10 + 58 36 26 18 854 980 10 + 59 21 24 28 17 972 10 + 60 17 34 3 449 971 10 + 61 12 24 13 126 541 10 + 62 24 58 19 168 297 10 + 63 27 69 10 34 588 10 + 64 15 77 9 154 393 10 + 65 62 77 20 49 308 10 + 66 49 73 25 532 753 10 + 67 67 5 25 291 404 10 + 68 56 39 36 577 812 10 + 69 37 47 6 165 290 10 + 70 37 56 5 668 968 10 + 71 57 68 15 98 537 10 + 72 47 16 25 22 915 10 + 73 44 17 9 143 564 10 + 74 46 13 8 681 802 10 + 75 49 11 18 27 711 10 + 76 49 42 13 281 382 10 + 77 53 43 14 821 948 10 + 78 61 52 3 324 559 10 + 79 57 48 23 377 476 10 + 80 56 37 6 719 968 10 + 81 55 54 26 268 599 10 + 82 15 47 16 23 761 10 + 83 14 37 11 21 842 10 + 84 11 31 7 425 522 10 + 85 16 22 41 110 727 10 + 86 4 18 35 230 623 10 + 87 28 18 26 397 470 10 + 88 26 52 9 219 448 10 + 89 26 35 15 409 981 10 + 90 31 67 3 225 654 10 + 91 15 19 1 222 964 10 + 92 22 22 2 18 159 10 + 93 18 24 22 691 969 10 + 94 26 27 27 190 749 10 + 95 25 24 20 14 793 10 + 96 22 27 11 344 953 10 + 97 25 21 12 462 823 10 + 98 19 21 10 21 748 10 + 99 20 26 9 328 437 10 + 100 18 18 17 821 965 10 diff --git a/jsprit-instances/instances/solomon/R211.txt b/jsprit-instances/instances/solomon/R211.txt new file mode 100644 index 00000000..3c7b246a --- /dev/null +++ b/jsprit-instances/instances/solomon/R211.txt @@ -0,0 +1,110 @@ +R211 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 35 35 0 0 1000 0 + 1 41 49 10 451 974 10 + 2 35 17 7 18 534 10 + 3 55 45 13 378 733 10 + 4 55 20 19 477 965 10 + 5 15 30 26 20 610 10 + 6 25 30 3 245 684 10 + 7 20 50 5 172 569 10 + 8 10 43 9 245 640 10 + 9 55 60 16 231 666 10 + 10 30 60 16 430 779 10 + 11 20 65 12 33 511 10 + 12 50 35 19 50 523 10 + 13 30 25 23 462 978 10 + 14 15 10 20 32 694 10 + 15 30 5 8 30 519 10 + 16 10 20 19 102 543 10 + 17 5 30 2 444 959 10 + 18 20 40 12 229 582 10 + 19 15 60 17 95 552 10 + 20 45 65 9 418 829 10 + 21 45 20 11 36 509 10 + 22 45 10 18 246 657 10 + 23 55 5 29 36 514 10 + 24 65 35 3 435 960 10 + 25 65 20 6 438 956 10 + 26 45 30 17 428 827 10 + 27 35 40 16 5 548 10 + 28 41 37 16 6 526 10 + 29 64 42 9 29 513 10 + 30 40 60 21 91 522 10 + 31 31 52 27 17 501 10 + 32 35 69 23 482 955 10 + 33 53 52 11 24 575 10 + 34 65 55 14 367 776 10 + 35 63 65 8 453 948 10 + 36 2 60 5 41 615 10 + 37 20 20 8 443 856 10 + 38 5 5 16 130 577 10 + 39 60 12 31 33 655 10 + 40 40 25 9 201 596 10 + 41 42 7 5 219 688 10 + 42 24 12 5 25 560 10 + 43 23 3 7 458 867 10 + 44 11 14 18 59 514 10 + 45 6 38 16 29 589 10 + 46 2 48 1 338 805 10 + 47 8 56 27 34 602 10 + 48 13 52 36 454 962 10 + 49 6 68 30 362 679 10 + 50 47 47 13 379 810 10 + 51 49 58 10 176 625 10 + 52 27 43 9 11 502 10 + 53 37 31 14 256 647 10 + 54 57 29 18 475 900 10 + 55 63 23 2 441 918 10 + 56 53 12 6 412 865 10 + 57 32 12 7 246 705 10 + 58 36 26 18 479 980 10 + 59 21 24 28 17 681 10 + 60 17 34 3 449 971 10 + 61 12 24 13 126 541 10 + 62 24 58 19 25 544 10 + 63 27 69 10 34 588 10 + 64 15 77 9 46 524 10 + 65 62 77 20 49 568 10 + 66 49 73 25 421 864 10 + 67 67 5 25 120 575 10 + 68 56 39 36 459 930 10 + 69 37 47 6 12 513 10 + 70 37 56 5 368 968 10 + 71 57 68 15 98 537 10 + 72 47 16 25 22 617 10 + 73 44 17 9 143 564 10 + 74 46 13 8 482 965 10 + 75 49 11 18 62 519 10 + 76 49 42 13 129 534 10 + 77 53 43 14 460 970 10 + 78 61 52 3 207 676 10 + 79 57 48 23 230 623 10 + 80 56 37 6 470 968 10 + 81 55 54 26 268 599 10 + 82 15 47 16 23 515 10 + 83 14 37 11 21 568 10 + 84 11 31 7 278 669 10 + 85 16 22 41 213 624 10 + 86 4 18 35 230 623 10 + 87 28 18 26 287 580 10 + 88 26 52 9 104 563 10 + 89 26 35 15 409 981 10 + 90 31 67 3 225 654 10 + 91 15 19 1 469 964 10 + 92 22 22 2 18 585 10 + 93 18 24 22 414 969 10 + 94 26 27 27 283 656 10 + 95 25 24 20 14 533 10 + 96 22 27 11 445 852 10 + 97 25 21 12 462 823 10 + 98 19 21 10 21 506 10 + 99 20 26 9 164 601 10 + 100 18 18 17 391 965 10 diff --git a/jsprit-instances/instances/solomon/RC101.txt b/jsprit-instances/instances/solomon/RC101.txt new file mode 100644 index 00000000..33660e19 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC101.txt @@ -0,0 +1,110 @@ +RC101 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 145 175 10 + 2 22 75 30 50 80 10 + 3 22 85 10 109 139 10 + 4 20 80 40 141 171 10 + 5 20 85 20 41 71 10 + 6 18 75 20 95 125 10 + 7 15 75 20 79 109 10 + 8 15 80 10 91 121 10 + 9 10 35 20 91 121 10 + 10 10 40 30 119 149 10 + 11 8 40 40 59 89 10 + 12 8 45 20 64 94 10 + 13 5 35 10 142 172 10 + 14 5 45 10 35 65 10 + 15 2 40 20 58 88 10 + 16 0 40 20 72 102 10 + 17 0 45 20 149 179 10 + 18 44 5 20 87 117 10 + 19 42 10 40 72 102 10 + 20 42 15 10 122 152 10 + 21 40 5 10 67 97 10 + 22 40 15 40 92 122 10 + 23 38 5 30 65 95 10 + 24 38 15 10 148 178 10 + 25 35 5 20 154 184 10 + 26 95 30 30 115 145 10 + 27 95 35 20 62 92 10 + 28 92 30 10 62 92 10 + 29 90 35 10 67 97 10 + 30 88 30 10 74 104 10 + 31 88 35 20 61 91 10 + 32 87 30 10 131 161 10 + 33 85 25 10 51 81 10 + 34 85 35 30 111 141 10 + 35 67 85 20 139 169 10 + 36 65 85 40 43 73 10 + 37 65 82 10 124 154 10 + 38 62 80 30 75 105 10 + 39 60 80 10 37 67 10 + 40 60 85 30 85 115 10 + 41 58 75 20 92 122 10 + 42 55 80 10 33 63 10 + 43 55 85 20 128 158 10 + 44 55 82 10 64 94 10 + 45 20 82 10 37 67 10 + 46 18 80 10 113 143 10 + 47 2 45 10 45 75 10 + 48 42 5 10 151 181 10 + 49 42 12 10 104 134 10 + 50 72 35 30 116 146 10 + 51 55 20 19 83 113 10 + 52 25 30 3 52 82 10 + 53 20 50 5 91 121 10 + 54 55 60 16 139 169 10 + 55 30 60 16 140 170 10 + 56 50 35 19 130 160 10 + 57 30 25 23 96 126 10 + 58 15 10 20 152 182 10 + 59 10 20 19 42 72 10 + 60 15 60 17 155 185 10 + 61 45 65 9 66 96 10 + 62 65 35 3 52 82 10 + 63 65 20 6 39 69 10 + 64 45 30 17 53 83 10 + 65 35 40 16 11 41 10 + 66 41 37 16 133 163 10 + 67 64 42 9 70 100 10 + 68 40 60 21 144 174 10 + 69 31 52 27 41 71 10 + 70 35 69 23 180 210 10 + 71 65 55 14 65 95 10 + 72 63 65 8 30 60 10 + 73 2 60 5 77 107 10 + 74 20 20 8 141 171 10 + 75 5 5 16 74 104 10 + 76 60 12 31 75 105 10 + 77 23 3 7 150 180 10 + 78 8 56 27 90 120 10 + 79 6 68 30 89 119 10 + 80 47 47 13 192 222 10 + 81 49 58 10 86 116 10 + 82 27 43 9 42 72 10 + 83 37 31 14 35 65 10 + 84 57 29 18 96 126 10 + 85 63 23 2 87 117 10 + 86 21 24 28 87 117 10 + 87 12 24 13 90 120 10 + 88 24 58 19 67 97 10 + 89 67 5 25 144 174 10 + 90 37 47 6 86 116 10 + 91 49 42 13 167 197 10 + 92 53 43 14 14 44 10 + 93 61 52 3 178 208 10 + 94 57 48 23 95 125 10 + 95 56 37 6 34 64 10 + 96 55 54 26 132 162 10 + 97 4 18 35 120 150 10 + 98 26 52 9 46 76 10 + 99 26 35 15 77 107 10 + 100 31 67 3 180 210 10 diff --git a/jsprit-instances/instances/solomon/RC102.txt b/jsprit-instances/instances/solomon/RC102.txt new file mode 100644 index 00000000..7e3713e3 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC102.txt @@ -0,0 +1,110 @@ +RC102 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 0 191 10 + 2 22 75 30 0 199 10 + 3 22 85 10 0 190 10 + 4 20 80 40 141 171 10 + 5 20 85 20 0 189 10 + 6 18 75 20 95 125 10 + 7 15 75 20 0 194 10 + 8 15 80 10 91 121 10 + 9 10 35 20 91 121 10 + 10 10 40 30 119 149 10 + 11 8 40 40 59 89 10 + 12 8 45 20 0 197 10 + 13 5 35 10 142 172 10 + 14 5 45 10 35 65 10 + 15 2 40 20 58 88 10 + 16 0 40 20 72 102 10 + 17 0 45 20 149 179 10 + 18 44 5 20 87 117 10 + 19 42 10 40 72 102 10 + 20 42 15 10 122 152 10 + 21 40 5 10 0 185 10 + 22 40 15 40 92 122 10 + 23 38 5 30 65 95 10 + 24 38 15 10 148 178 10 + 25 35 5 20 154 184 10 + 26 95 30 30 0 171 10 + 27 95 35 20 62 92 10 + 28 92 30 10 62 92 10 + 29 90 35 10 67 97 10 + 30 88 30 10 74 104 10 + 31 88 35 20 0 179 10 + 32 87 30 10 131 161 10 + 33 85 25 10 51 81 10 + 34 85 35 30 0 182 10 + 35 67 85 20 139 169 10 + 36 65 85 40 43 73 10 + 37 65 82 10 0 189 10 + 38 62 80 30 75 105 10 + 39 60 80 10 37 67 10 + 40 60 85 30 85 115 10 + 41 58 75 20 92 122 10 + 42 55 80 10 33 63 10 + 43 55 85 20 128 158 10 + 44 55 82 10 64 94 10 + 45 20 82 10 37 67 10 + 46 18 80 10 113 143 10 + 47 2 45 10 45 75 10 + 48 42 5 10 0 184 10 + 49 42 12 10 104 134 10 + 50 72 35 30 0 194 10 + 51 55 20 19 83 113 10 + 52 25 30 3 0 205 10 + 53 20 50 5 91 121 10 + 54 55 60 16 139 169 10 + 55 30 60 16 140 170 10 + 56 50 35 19 130 160 10 + 57 30 25 23 96 126 10 + 58 15 10 20 152 182 10 + 59 10 20 19 0 187 10 + 60 15 60 17 155 185 10 + 61 45 65 9 66 96 10 + 62 65 35 3 52 82 10 + 63 65 20 6 39 69 10 + 64 45 30 17 53 83 10 + 65 35 40 16 11 41 10 + 66 41 37 16 133 163 10 + 67 64 42 9 70 100 10 + 68 40 60 21 144 174 10 + 69 31 52 27 41 71 10 + 70 35 69 23 180 210 10 + 71 65 55 14 65 95 10 + 72 63 65 8 0 202 10 + 73 2 60 5 77 107 10 + 74 20 20 8 141 171 10 + 75 5 5 16 0 172 10 + 76 60 12 31 75 105 10 + 77 23 3 7 150 180 10 + 78 8 56 27 90 120 10 + 79 6 68 30 89 119 10 + 80 47 47 13 192 222 10 + 81 49 58 10 86 116 10 + 82 27 43 9 0 215 10 + 83 37 31 14 0 210 10 + 84 57 29 18 96 126 10 + 85 63 23 2 0 194 10 + 86 21 24 28 87 117 10 + 87 12 24 13 90 120 10 + 88 24 58 19 67 97 10 + 89 67 5 25 144 174 10 + 90 37 47 6 86 116 10 + 91 49 42 13 0 217 10 + 92 53 43 14 14 44 10 + 93 61 52 3 178 208 10 + 94 57 48 23 0 212 10 + 95 56 37 6 0 209 10 + 96 55 54 26 0 214 10 + 97 4 18 35 120 150 10 + 98 26 52 9 0 215 10 + 99 26 35 15 77 107 10 + 100 31 67 3 180 210 10 diff --git a/jsprit-instances/instances/solomon/RC103.txt b/jsprit-instances/instances/solomon/RC103.txt new file mode 100644 index 00000000..55753fb4 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC103.txt @@ -0,0 +1,110 @@ +RC103 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 0 191 10 + 2 22 75 30 0 199 10 + 3 22 85 10 0 190 10 + 4 20 80 40 141 171 10 + 5 20 85 20 0 189 10 + 6 18 75 20 95 125 10 + 7 15 75 20 0 194 10 + 8 15 80 10 91 121 10 + 9 10 35 20 91 121 10 + 10 10 40 30 119 149 10 + 11 8 40 40 59 89 10 + 12 8 45 20 0 197 10 + 13 5 35 10 142 172 10 + 14 5 45 10 0 194 10 + 15 2 40 20 58 88 10 + 16 0 40 20 0 188 10 + 17 0 45 20 149 179 10 + 18 44 5 20 0 184 10 + 19 42 10 40 0 189 10 + 20 42 15 10 0 194 10 + 21 40 5 10 0 185 10 + 22 40 15 40 92 122 10 + 23 38 5 30 65 95 10 + 24 38 15 10 0 194 10 + 25 35 5 20 154 184 10 + 26 95 30 30 0 171 10 + 27 95 35 20 62 92 10 + 28 92 30 10 0 174 10 + 29 90 35 10 0 177 10 + 30 88 30 10 74 104 10 + 31 88 35 20 0 179 10 + 32 87 30 10 0 178 10 + 33 85 25 10 51 81 10 + 34 85 35 30 0 182 10 + 35 67 85 20 139 169 10 + 36 65 85 40 43 73 10 + 37 65 82 10 0 189 10 + 38 62 80 30 75 105 10 + 39 60 80 10 37 67 10 + 40 60 85 30 85 115 10 + 41 58 75 20 92 122 10 + 42 55 80 10 33 63 10 + 43 55 85 20 0 191 10 + 44 55 82 10 64 94 10 + 45 20 82 10 37 67 10 + 46 18 80 10 0 192 10 + 47 2 45 10 0 191 10 + 48 42 5 10 0 184 10 + 49 42 12 10 104 134 10 + 50 72 35 30 0 194 10 + 51 55 20 19 0 196 10 + 52 25 30 3 0 205 10 + 53 20 50 5 91 121 10 + 54 55 60 16 0 211 10 + 55 30 60 16 140 170 10 + 56 50 35 19 130 160 10 + 57 30 25 23 0 203 10 + 58 15 10 20 152 182 10 + 59 10 20 19 0 187 10 + 60 15 60 17 0 203 10 + 61 45 65 9 0 214 10 + 62 65 35 3 52 82 10 + 63 65 20 6 0 190 10 + 64 45 30 17 53 83 10 + 65 35 40 16 11 41 10 + 66 41 37 16 133 163 10 + 67 64 42 9 70 100 10 + 68 40 60 21 144 174 10 + 69 31 52 27 41 71 10 + 70 35 69 23 180 210 10 + 71 65 55 14 0 204 10 + 72 63 65 8 0 202 10 + 73 2 60 5 0 190 10 + 74 20 20 8 141 171 10 + 75 5 5 16 0 172 10 + 76 60 12 31 75 105 10 + 77 23 3 7 150 180 10 + 78 8 56 27 90 120 10 + 79 6 68 30 89 119 10 + 80 47 47 13 192 222 10 + 81 49 58 10 0 217 10 + 82 27 43 9 0 215 10 + 83 37 31 14 0 210 10 + 84 57 29 18 96 126 10 + 85 63 23 2 0 194 10 + 86 21 24 28 0 197 10 + 87 12 24 13 90 120 10 + 88 24 58 19 67 97 10 + 89 67 5 25 0 177 10 + 90 37 47 6 0 225 10 + 91 49 42 13 0 217 10 + 92 53 43 14 14 44 10 + 93 61 52 3 178 208 10 + 94 57 48 23 0 212 10 + 95 56 37 6 0 209 10 + 96 55 54 26 0 214 10 + 97 4 18 35 0 181 10 + 98 26 52 9 0 215 10 + 99 26 35 15 77 107 10 + 100 31 67 3 180 210 10 diff --git a/jsprit-instances/instances/solomon/RC104.txt b/jsprit-instances/instances/solomon/RC104.txt new file mode 100644 index 00000000..e446af7e --- /dev/null +++ b/jsprit-instances/instances/solomon/RC104.txt @@ -0,0 +1,110 @@ +RC104 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 0 191 10 + 2 22 75 30 0 199 10 + 3 22 85 10 0 190 10 + 4 20 80 40 141 171 10 + 5 20 85 20 0 189 10 + 6 18 75 20 0 196 10 + 7 15 75 20 0 194 10 + 8 15 80 10 91 121 10 + 9 10 35 20 91 121 10 + 10 10 40 30 0 198 10 + 11 8 40 40 59 89 10 + 12 8 45 20 0 197 10 + 13 5 35 10 142 172 10 + 14 5 45 10 0 194 10 + 15 2 40 20 58 88 10 + 16 0 40 20 0 188 10 + 17 0 45 20 0 189 10 + 18 44 5 20 0 184 10 + 19 42 10 40 0 189 10 + 20 42 15 10 0 194 10 + 21 40 5 10 0 185 10 + 22 40 15 40 0 195 10 + 23 38 5 30 65 95 10 + 24 38 15 10 0 194 10 + 25 35 5 20 154 184 10 + 26 95 30 30 0 171 10 + 27 95 35 20 0 172 10 + 28 92 30 10 0 174 10 + 29 90 35 10 0 177 10 + 30 88 30 10 0 178 10 + 31 88 35 20 0 179 10 + 32 87 30 10 0 178 10 + 33 85 25 10 0 178 10 + 34 85 35 30 0 182 10 + 35 67 85 20 0 185 10 + 36 65 85 40 0 186 10 + 37 65 82 10 0 189 10 + 38 62 80 30 75 105 10 + 39 60 80 10 0 193 10 + 40 60 85 30 0 189 10 + 41 58 75 20 0 199 10 + 42 55 80 10 0 196 10 + 43 55 85 20 0 191 10 + 44 55 82 10 64 94 10 + 45 20 82 10 0 192 10 + 46 18 80 10 0 192 10 + 47 2 45 10 0 191 10 + 48 42 5 10 0 184 10 + 49 42 12 10 0 191 10 + 50 72 35 30 0 194 10 + 51 55 20 19 0 196 10 + 52 25 30 3 0 205 10 + 53 20 50 5 91 121 10 + 54 55 60 16 0 211 10 + 55 30 60 16 140 170 10 + 56 50 35 19 0 211 10 + 57 30 25 23 0 203 10 + 58 15 10 20 152 182 10 + 59 10 20 19 0 187 10 + 60 15 60 17 0 203 10 + 61 45 65 9 0 214 10 + 62 65 35 3 52 82 10 + 63 65 20 6 0 190 10 + 64 45 30 17 0 209 10 + 65 35 40 16 0 218 10 + 66 41 37 16 0 216 10 + 67 64 42 9 70 100 10 + 68 40 60 21 0 220 10 + 69 31 52 27 41 71 10 + 70 35 69 23 0 210 10 + 71 65 55 14 0 204 10 + 72 63 65 8 0 202 10 + 73 2 60 5 0 190 10 + 74 20 20 8 141 171 10 + 75 5 5 16 0 172 10 + 76 60 12 31 75 105 10 + 77 23 3 7 150 180 10 + 78 8 56 27 0 197 10 + 79 6 68 30 89 119 10 + 80 47 47 13 0 222 10 + 81 49 58 10 0 217 10 + 82 27 43 9 0 215 10 + 83 37 31 14 0 210 10 + 84 57 29 18 96 126 10 + 85 63 23 2 0 194 10 + 86 21 24 28 0 197 10 + 87 12 24 13 90 120 10 + 88 24 58 19 0 212 10 + 89 67 5 25 0 177 10 + 90 37 47 6 0 225 10 + 91 49 42 13 0 217 10 + 92 53 43 14 14 44 10 + 93 61 52 3 0 208 10 + 94 57 48 23 0 212 10 + 95 56 37 6 0 209 10 + 96 55 54 26 0 214 10 + 97 4 18 35 0 181 10 + 98 26 52 9 0 215 10 + 99 26 35 15 77 107 10 + 100 31 67 3 180 210 10 diff --git a/jsprit-instances/instances/solomon/RC105.txt b/jsprit-instances/instances/solomon/RC105.txt new file mode 100644 index 00000000..e60154c9 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC105.txt @@ -0,0 +1,110 @@ +RC105 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 71 191 10 + 2 22 75 30 30 150 10 + 3 22 85 10 64 184 10 + 4 20 80 40 151 161 10 + 5 20 85 20 40 160 10 + 6 18 75 20 96 123 10 + 7 15 75 20 35 155 10 + 8 15 80 10 101 111 10 + 9 10 35 20 101 111 10 + 10 10 40 30 123 144 10 + 11 8 40 40 69 79 10 + 12 8 45 20 32 152 10 + 13 5 35 10 152 162 10 + 14 5 45 10 35 117 10 + 15 2 40 20 68 78 10 + 16 0 40 20 59 114 10 + 17 0 45 20 147 180 10 + 18 44 5 20 79 124 10 + 19 42 10 40 58 115 10 + 20 42 15 10 111 162 10 + 21 40 5 10 45 165 10 + 22 40 15 40 94 119 10 + 23 38 5 30 75 85 10 + 24 38 15 10 128 194 10 + 25 35 5 20 171 181 10 + 26 95 30 30 58 171 10 + 27 95 35 20 60 93 10 + 28 92 30 10 55 120 10 + 29 90 35 10 52 112 10 + 30 88 30 10 75 102 10 + 31 88 35 20 50 170 10 + 32 87 30 10 116 175 10 + 33 85 25 10 51 85 10 + 34 85 35 30 62 182 10 + 35 67 85 20 138 169 10 + 36 65 85 40 43 78 10 + 37 65 82 10 69 189 10 + 38 62 80 30 85 95 10 + 39 60 80 10 36 74 10 + 40 60 85 30 87 112 10 + 41 58 75 20 92 121 10 + 42 55 80 10 33 66 10 + 43 55 85 20 117 168 10 + 44 55 82 10 74 84 10 + 45 20 82 10 37 72 10 + 46 18 80 10 98 157 10 + 47 2 45 10 38 109 10 + 48 42 5 10 64 184 10 + 49 42 12 10 109 128 10 + 50 72 35 30 71 191 10 + 51 55 20 19 69 126 10 + 52 25 30 3 25 145 10 + 53 20 50 5 101 111 10 + 54 55 60 16 127 180 10 + 55 30 60 16 150 160 10 + 56 50 35 19 130 159 10 + 57 30 25 23 82 139 10 + 58 15 10 20 172 182 10 + 59 10 20 19 42 162 10 + 60 15 60 17 137 202 10 + 61 45 65 9 55 106 10 + 62 65 35 3 62 72 10 + 63 65 20 6 39 108 10 + 64 45 30 17 53 82 10 + 65 35 40 16 11 43 10 + 66 41 37 16 134 161 10 + 67 64 42 9 80 90 10 + 68 40 60 21 144 173 10 + 69 31 52 27 51 61 10 + 70 35 69 23 172 210 10 + 71 65 55 14 52 107 10 + 72 63 65 8 27 147 10 + 73 2 60 5 65 118 10 + 74 20 20 8 151 161 10 + 75 5 5 16 57 172 10 + 76 60 12 31 85 95 10 + 77 23 3 7 163 173 10 + 78 8 56 27 90 119 10 + 79 6 68 30 99 109 10 + 80 47 47 13 190 222 10 + 81 49 58 10 80 121 10 + 82 27 43 9 14 134 10 + 83 37 31 14 19 139 10 + 84 57 29 18 106 116 10 + 85 63 23 2 42 162 10 + 86 21 24 28 77 126 10 + 87 12 24 13 100 110 10 + 88 24 58 19 67 96 10 + 89 67 5 25 105 177 10 + 90 37 47 6 74 127 10 + 91 49 42 13 97 217 10 + 92 53 43 14 15 25 10 + 93 61 52 3 173 208 10 + 94 57 48 23 50 170 10 + 95 56 37 6 20 140 10 + 96 55 54 26 87 207 10 + 97 4 18 35 112 157 10 + 98 26 52 9 14 134 10 + 99 26 35 15 87 97 10 + 100 31 67 3 200 210 10 diff --git a/jsprit-instances/instances/solomon/RC106.txt b/jsprit-instances/instances/solomon/RC106.txt new file mode 100644 index 00000000..0dd9a683 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC106.txt @@ -0,0 +1,110 @@ +RC106 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 130 190 10 + 2 22 75 30 35 95 10 + 3 22 85 10 94 154 10 + 4 20 80 40 126 186 10 + 5 20 85 20 40 100 10 + 6 18 75 20 80 140 10 + 7 15 75 20 64 124 10 + 8 15 80 10 76 136 10 + 9 10 35 20 76 136 10 + 10 10 40 30 104 164 10 + 11 8 40 40 44 104 10 + 12 8 45 20 49 109 10 + 13 5 35 10 127 187 10 + 14 5 45 10 35 95 10 + 15 2 40 20 43 103 10 + 16 0 40 20 57 117 10 + 17 0 45 20 129 189 10 + 18 44 5 20 72 132 10 + 19 42 10 40 57 117 10 + 20 42 15 10 107 167 10 + 21 40 5 10 52 112 10 + 22 40 15 40 77 137 10 + 23 38 5 30 50 110 10 + 24 38 15 10 133 193 10 + 25 35 5 20 124 184 10 + 26 95 30 30 100 160 10 + 27 95 35 20 57 117 10 + 28 92 30 10 55 115 10 + 29 90 35 10 52 112 10 + 30 88 30 10 59 119 10 + 31 88 35 20 50 110 10 + 32 87 30 10 116 176 10 + 33 85 25 10 51 111 10 + 34 85 35 30 96 156 10 + 35 67 85 20 124 184 10 + 36 65 85 40 43 103 10 + 37 65 82 10 109 169 10 + 38 62 80 30 60 120 10 + 39 60 80 10 36 96 10 + 40 60 85 30 70 130 10 + 41 58 75 20 77 137 10 + 42 55 80 10 33 93 10 + 43 55 85 20 113 173 10 + 44 55 82 10 49 109 10 + 45 20 82 10 37 97 10 + 46 18 80 10 98 158 10 + 47 2 45 10 38 98 10 + 48 42 5 10 124 184 10 + 49 42 12 10 89 149 10 + 50 72 35 30 101 161 10 + 51 55 20 19 68 128 10 + 52 25 30 3 37 97 10 + 53 20 50 5 76 136 10 + 54 55 60 16 124 184 10 + 55 30 60 16 125 185 10 + 56 50 35 19 115 175 10 + 57 30 25 23 81 141 10 + 58 15 10 20 122 182 10 + 59 10 20 19 42 102 10 + 60 15 60 17 140 200 10 + 61 45 65 9 51 111 10 + 62 65 35 3 37 97 10 + 63 65 20 6 39 99 10 + 64 45 30 17 38 98 10 + 65 35 40 16 11 71 10 + 66 41 37 16 118 178 10 + 67 64 42 9 55 115 10 + 68 40 60 21 129 189 10 + 69 31 52 27 26 86 10 + 70 35 69 23 150 210 10 + 71 65 55 14 50 110 10 + 72 63 65 8 27 87 10 + 73 2 60 5 62 122 10 + 74 20 20 8 126 186 10 + 75 5 5 16 59 119 10 + 76 60 12 31 60 120 10 + 77 23 3 7 120 180 10 + 78 8 56 27 75 135 10 + 79 6 68 30 74 134 10 + 80 47 47 13 162 222 10 + 81 49 58 10 71 131 10 + 82 27 43 9 27 87 10 + 83 37 31 14 20 80 10 + 84 57 29 18 81 141 10 + 85 63 23 2 72 132 10 + 86 21 24 28 72 132 10 + 87 12 24 13 75 135 10 + 88 24 58 19 52 112 10 + 89 67 5 25 117 177 10 + 90 37 47 6 71 131 10 + 91 49 42 13 152 212 10 + 92 53 43 14 14 74 10 + 93 61 52 3 148 208 10 + 94 57 48 23 80 140 10 + 95 56 37 6 20 80 10 + 96 55 54 26 117 177 10 + 97 4 18 35 105 165 10 + 98 26 52 9 31 91 10 + 99 26 35 15 62 122 10 + 100 31 67 3 150 210 10 diff --git a/jsprit-instances/instances/solomon/RC107.txt b/jsprit-instances/instances/solomon/RC107.txt new file mode 100644 index 00000000..73c7568f --- /dev/null +++ b/jsprit-instances/instances/solomon/RC107.txt @@ -0,0 +1,110 @@ +RC107 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 125 191 10 + 2 22 75 30 32 97 10 + 3 22 85 10 101 146 10 + 4 20 80 40 71 193 10 + 5 20 85 20 40 113 10 + 6 18 75 20 55 164 10 + 7 15 75 20 69 118 10 + 8 15 80 10 56 155 10 + 9 10 35 20 51 160 10 + 10 10 40 30 90 177 10 + 11 8 40 40 33 152 10 + 12 8 45 20 49 108 10 + 13 5 35 10 62 191 10 + 14 5 45 10 35 117 10 + 15 2 40 20 39 161 10 + 16 0 40 20 59 114 10 + 17 0 45 20 60 189 10 + 18 44 5 20 79 124 10 + 19 42 10 40 58 115 10 + 20 42 15 10 111 162 10 + 21 40 5 10 52 111 10 + 22 40 15 40 55 158 10 + 23 38 5 30 45 164 10 + 24 38 15 10 128 194 10 + 25 35 5 20 54 184 10 + 26 95 30 30 105 154 10 + 27 95 35 20 57 172 10 + 28 92 30 10 55 120 10 + 29 90 35 10 52 112 10 + 30 88 30 10 52 159 10 + 31 88 35 20 50 110 10 + 32 87 30 10 116 175 10 + 33 85 25 10 51 178 10 + 34 85 35 30 100 151 10 + 35 67 85 20 61 185 10 + 36 65 85 40 43 186 10 + 37 65 82 10 113 164 10 + 38 62 80 30 37 148 10 + 39 60 80 10 36 191 10 + 40 60 85 30 50 149 10 + 41 58 75 20 48 165 10 + 42 55 80 10 33 166 10 + 43 55 85 20 117 168 10 + 44 55 82 10 35 148 10 + 45 20 82 10 37 177 10 + 46 18 80 10 98 157 10 + 47 2 45 10 38 109 10 + 48 42 5 10 120 184 10 + 49 42 12 10 79 158 10 + 50 72 35 30 104 157 10 + 51 55 20 19 69 126 10 + 52 25 30 3 36 97 10 + 53 20 50 5 57 154 10 + 54 55 60 16 127 180 10 + 55 30 60 16 95 214 10 + 56 50 35 19 88 201 10 + 57 30 25 23 82 139 10 + 58 15 10 20 56 182 10 + 59 10 20 19 42 125 10 + 60 15 60 17 137 202 10 + 61 45 65 9 55 106 10 + 62 65 35 3 29 158 10 + 63 65 20 6 39 108 10 + 64 45 30 17 20 139 10 + 65 35 40 16 11 140 10 + 66 41 37 16 92 203 10 + 67 64 42 9 28 141 10 + 68 40 60 21 100 217 10 + 69 31 52 27 9 134 10 + 70 35 69 23 60 210 10 + 71 65 55 14 52 107 10 + 72 63 65 8 27 101 10 + 73 2 60 5 65 118 10 + 74 20 20 8 72 193 10 + 75 5 5 16 60 117 10 + 76 60 12 31 42 143 10 + 77 23 3 7 52 180 10 + 78 8 56 27 46 163 10 + 79 6 68 30 54 153 10 + 80 47 47 13 97 222 10 + 81 49 58 10 80 121 10 + 82 27 43 9 26 87 10 + 83 37 31 14 19 87 10 + 84 57 29 18 62 159 10 + 85 63 23 2 76 127 10 + 86 21 24 28 77 126 10 + 87 12 24 13 68 141 10 + 88 24 58 19 24 139 10 + 89 67 5 25 105 177 10 + 90 37 47 6 74 127 10 + 91 49 42 13 151 212 10 + 92 53 43 14 14 155 10 + 93 61 52 3 69 208 10 + 94 57 48 23 86 133 10 + 95 56 37 6 20 84 10 + 96 55 54 26 121 172 10 + 97 4 18 35 112 157 10 + 98 26 52 9 30 91 10 + 99 26 35 15 37 146 10 + 100 31 67 3 66 210 10 diff --git a/jsprit-instances/instances/solomon/RC108.txt b/jsprit-instances/instances/solomon/RC108.txt new file mode 100644 index 00000000..9a465690 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC108.txt @@ -0,0 +1,110 @@ +RC108 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 240 0 + 1 25 85 20 49 191 10 + 2 22 75 30 30 168 10 + 3 22 85 10 95 152 10 + 4 20 80 40 69 193 10 + 5 20 85 20 40 189 10 + 6 18 75 20 60 159 10 + 7 15 75 20 54 133 10 + 8 15 80 10 67 144 10 + 9 10 35 20 57 154 10 + 10 10 40 30 106 161 10 + 11 8 40 40 33 152 10 + 12 8 45 20 32 148 10 + 13 5 35 10 53 191 10 + 14 5 45 10 35 194 10 + 15 2 40 20 39 163 10 + 16 0 40 20 41 141 10 + 17 0 45 20 51 189 10 + 18 44 5 20 73 130 10 + 19 42 10 40 40 148 10 + 20 42 15 10 94 179 10 + 21 40 5 10 45 161 10 + 22 40 15 40 64 149 10 + 23 38 5 30 45 164 10 + 24 38 15 10 51 194 10 + 25 35 5 20 45 183 10 + 26 95 30 30 90 169 10 + 27 95 35 20 57 172 10 + 28 92 30 10 55 174 10 + 29 90 35 10 52 174 10 + 30 88 30 10 52 147 10 + 31 88 35 20 50 172 10 + 32 87 30 10 61 178 10 + 33 85 25 10 51 178 10 + 34 85 35 30 83 168 10 + 35 67 85 20 57 185 10 + 36 65 85 40 43 186 10 + 37 65 82 10 95 182 10 + 38 62 80 30 38 141 10 + 39 60 80 10 36 193 10 + 40 60 85 30 61 138 10 + 41 58 75 20 49 164 10 + 42 55 80 10 33 180 10 + 43 55 85 20 100 185 10 + 44 55 82 10 35 142 10 + 45 20 82 10 37 192 10 + 46 18 80 10 71 184 10 + 47 2 45 10 38 191 10 + 48 42 5 10 50 184 10 + 49 42 12 10 99 138 10 + 50 72 35 30 83 178 10 + 51 55 20 19 45 150 10 + 52 25 30 3 25 150 10 + 53 20 50 5 68 143 10 + 54 55 60 16 107 200 10 + 55 30 60 16 95 214 10 + 56 50 35 19 91 198 10 + 57 30 25 23 56 165 10 + 58 15 10 20 51 182 10 + 59 10 20 19 42 187 10 + 60 15 60 17 62 203 10 + 61 45 65 9 37 124 10 + 62 65 35 3 29 168 10 + 63 65 20 6 39 190 10 + 64 45 30 17 20 139 10 + 65 35 40 16 11 150 10 + 66 41 37 16 97 198 10 + 67 64 42 9 31 138 10 + 68 40 60 21 101 216 10 + 69 31 52 27 9 139 10 + 70 35 69 23 30 210 10 + 71 65 55 14 30 129 10 + 72 63 65 8 27 202 10 + 73 2 60 5 46 137 10 + 74 20 20 8 71 193 10 + 75 5 5 16 57 165 10 + 76 60 12 31 48 131 10 + 77 23 3 7 49 180 10 + 78 8 56 27 47 162 10 + 79 6 68 30 65 142 10 + 80 47 47 13 93 222 10 + 81 49 58 10 78 123 10 + 82 27 43 9 14 140 10 + 83 37 31 14 19 172 10 + 84 57 29 18 73 148 10 + 85 63 23 2 59 144 10 + 86 21 24 28 63 140 10 + 87 12 24 13 91 118 10 + 88 24 58 19 27 136 10 + 89 67 5 25 52 177 10 + 90 37 47 6 53 148 10 + 91 49 42 13 89 217 10 + 92 53 43 14 14 177 10 + 93 61 52 3 50 208 10 + 94 57 48 23 76 143 10 + 95 56 37 6 20 159 10 + 96 55 54 26 105 188 10 + 97 4 18 35 104 165 10 + 98 26 52 9 14 136 10 + 99 26 35 15 42 141 10 + 100 31 67 3 43 210 10 diff --git a/jsprit-instances/instances/solomon/RC201.txt b/jsprit-instances/instances/solomon/RC201.txt new file mode 100644 index 00000000..37015cd9 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC201.txt @@ -0,0 +1,110 @@ +RC201 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 673 793 10 + 2 22 75 30 152 272 10 + 3 22 85 10 471 591 10 + 4 20 80 40 644 764 10 + 5 20 85 20 73 193 10 + 6 18 75 20 388 508 10 + 7 15 75 20 300 420 10 + 8 15 80 10 367 487 10 + 9 10 35 20 371 491 10 + 10 10 40 30 519 639 10 + 11 8 40 40 195 315 10 + 12 8 45 20 223 343 10 + 13 5 35 10 653 773 10 + 14 5 45 10 35 155 10 + 15 2 40 20 174 294 10 + 16 0 40 20 255 375 10 + 17 0 45 20 703 823 10 + 18 44 5 20 335 455 10 + 19 42 10 40 254 374 10 + 20 42 15 10 537 657 10 + 21 40 5 10 215 335 10 + 22 40 15 40 375 495 10 + 23 38 5 30 201 321 10 + 24 38 15 10 681 801 10 + 25 35 5 20 784 904 10 + 26 95 30 30 529 649 10 + 27 95 35 20 146 266 10 + 28 92 30 10 149 269 10 + 29 90 35 10 194 314 10 + 30 88 30 10 246 366 10 + 31 88 35 20 165 285 10 + 32 87 30 10 621 741 10 + 33 85 25 10 80 200 10 + 34 85 35 30 487 607 10 + 35 67 85 20 657 777 10 + 36 65 85 40 43 163 10 + 37 65 82 10 557 677 10 + 38 62 80 30 278 398 10 + 39 60 80 10 64 184 10 + 40 60 85 30 329 449 10 + 41 58 75 20 376 496 10 + 42 55 80 10 33 153 10 + 43 55 85 20 574 694 10 + 44 55 82 10 217 337 10 + 45 20 82 10 37 157 10 + 46 18 80 10 489 609 10 + 47 2 45 10 105 225 10 + 48 42 5 10 732 852 10 + 49 42 12 10 440 560 10 + 50 72 35 30 507 627 10 + 51 55 20 19 326 446 10 + 52 25 30 3 175 295 10 + 53 20 50 5 375 495 10 + 54 55 60 16 601 721 10 + 55 30 60 16 599 719 10 + 56 50 35 19 557 677 10 + 57 30 25 23 397 517 10 + 58 15 10 20 782 902 10 + 59 10 20 19 42 162 10 + 60 15 60 17 694 814 10 + 61 45 65 9 258 378 10 + 62 65 35 3 167 287 10 + 63 65 20 6 39 159 10 + 64 45 30 17 191 311 10 + 65 35 40 16 11 131 10 + 66 41 37 16 566 686 10 + 67 64 42 9 268 388 10 + 68 40 60 21 612 732 10 + 69 31 52 27 157 277 10 + 70 35 69 23 810 930 10 + 71 65 55 14 241 361 10 + 72 63 65 8 60 180 10 + 73 2 60 5 286 406 10 + 74 20 20 8 645 765 10 + 75 5 5 16 232 352 10 + 76 60 12 31 268 388 10 + 77 23 3 7 764 884 10 + 78 8 56 27 365 485 10 + 79 6 68 30 352 472 10 + 80 47 47 13 822 942 10 + 81 49 58 10 355 475 10 + 82 27 43 9 152 272 10 + 83 37 31 14 105 225 10 + 84 57 29 18 395 515 10 + 85 63 23 2 344 464 10 + 86 21 24 28 349 469 10 + 87 12 24 13 359 479 10 + 88 24 58 19 260 380 10 + 89 67 5 25 713 833 10 + 90 37 47 6 359 479 10 + 91 49 42 13 719 839 10 + 92 53 43 14 14 134 10 + 93 61 52 3 808 928 10 + 94 57 48 23 392 512 10 + 95 56 37 6 100 220 10 + 96 55 54 26 562 682 10 + 97 4 18 35 547 667 10 + 98 26 52 9 172 292 10 + 99 26 35 15 308 428 10 + 100 31 67 3 810 930 10 diff --git a/jsprit-instances/instances/solomon/RC202.txt b/jsprit-instances/instances/solomon/RC202.txt new file mode 100644 index 00000000..2119ab64 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC202.txt @@ -0,0 +1,110 @@ +RC202 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 0 911 10 + 2 22 75 30 0 919 10 + 3 22 85 10 0 910 10 + 4 20 80 40 644 764 10 + 5 20 85 20 0 909 10 + 6 18 75 20 388 508 10 + 7 15 75 20 0 914 10 + 8 15 80 10 367 487 10 + 9 10 35 20 371 491 10 + 10 10 40 30 519 639 10 + 11 8 40 40 195 315 10 + 12 8 45 20 0 917 10 + 13 5 35 10 653 773 10 + 14 5 45 10 35 155 10 + 15 2 40 20 174 294 10 + 16 0 40 20 255 375 10 + 17 0 45 20 703 823 10 + 18 44 5 20 335 455 10 + 19 42 10 40 254 374 10 + 20 42 15 10 537 657 10 + 21 40 5 10 0 905 10 + 22 40 15 40 375 495 10 + 23 38 5 30 201 321 10 + 24 38 15 10 681 801 10 + 25 35 5 20 784 904 10 + 26 95 30 30 0 891 10 + 27 95 35 20 146 266 10 + 28 92 30 10 149 269 10 + 29 90 35 10 194 314 10 + 30 88 30 10 246 366 10 + 31 88 35 20 0 899 10 + 32 87 30 10 621 741 10 + 33 85 25 10 80 200 10 + 34 85 35 30 0 902 10 + 35 67 85 20 657 777 10 + 36 65 85 40 43 163 10 + 37 65 82 10 0 909 10 + 38 62 80 30 278 398 10 + 39 60 80 10 64 184 10 + 40 60 85 30 329 449 10 + 41 58 75 20 376 496 10 + 42 55 80 10 33 153 10 + 43 55 85 20 574 694 10 + 44 55 82 10 217 337 10 + 45 20 82 10 37 157 10 + 46 18 80 10 489 609 10 + 47 2 45 10 105 225 10 + 48 42 5 10 0 904 10 + 49 42 12 10 440 560 10 + 50 72 35 30 0 914 10 + 51 55 20 19 326 446 10 + 52 25 30 3 0 925 10 + 53 20 50 5 375 495 10 + 54 55 60 16 601 721 10 + 55 30 60 16 599 719 10 + 56 50 35 19 557 677 10 + 57 30 25 23 397 517 10 + 58 15 10 20 782 902 10 + 59 10 20 19 0 907 10 + 60 15 60 17 694 814 10 + 61 45 65 9 258 378 10 + 62 65 35 3 167 287 10 + 63 65 20 6 39 159 10 + 64 45 30 17 191 311 10 + 65 35 40 16 11 131 10 + 66 41 37 16 566 686 10 + 67 64 42 9 268 388 10 + 68 40 60 21 612 732 10 + 69 31 52 27 157 277 10 + 70 35 69 23 810 930 10 + 71 65 55 14 241 361 10 + 72 63 65 8 0 922 10 + 73 2 60 5 286 406 10 + 74 20 20 8 645 765 10 + 75 5 5 16 0 892 10 + 76 60 12 31 268 388 10 + 77 23 3 7 764 884 10 + 78 8 56 27 365 485 10 + 79 6 68 30 352 472 10 + 80 47 47 13 822 942 10 + 81 49 58 10 355 475 10 + 82 27 43 9 0 935 10 + 83 37 31 14 0 930 10 + 84 57 29 18 395 515 10 + 85 63 23 2 0 914 10 + 86 21 24 28 349 469 10 + 87 12 24 13 359 479 10 + 88 24 58 19 260 380 10 + 89 67 5 25 713 833 10 + 90 37 47 6 359 479 10 + 91 49 42 13 0 937 10 + 92 53 43 14 14 134 10 + 93 61 52 3 808 928 10 + 94 57 48 23 0 932 10 + 95 56 37 6 0 929 10 + 96 55 54 26 0 934 10 + 97 4 18 35 547 667 10 + 98 26 52 9 0 935 10 + 99 26 35 15 308 428 10 + 100 31 67 3 810 930 10 diff --git a/jsprit-instances/instances/solomon/RC203.txt b/jsprit-instances/instances/solomon/RC203.txt new file mode 100644 index 00000000..627d34a8 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC203.txt @@ -0,0 +1,110 @@ +RC203 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 0 911 10 + 2 22 75 30 0 919 10 + 3 22 85 10 0 910 10 + 4 20 80 40 644 764 10 + 5 20 85 20 0 909 10 + 6 18 75 20 388 508 10 + 7 15 75 20 0 914 10 + 8 15 80 10 367 487 10 + 9 10 35 20 371 491 10 + 10 10 40 30 519 639 10 + 11 8 40 40 195 315 10 + 12 8 45 20 0 917 10 + 13 5 35 10 653 773 10 + 14 5 45 10 0 914 10 + 15 2 40 20 174 294 10 + 16 0 40 20 0 908 10 + 17 0 45 20 703 823 10 + 18 44 5 20 0 904 10 + 19 42 10 40 0 909 10 + 20 42 15 10 0 914 10 + 21 40 5 10 0 905 10 + 22 40 15 40 375 495 10 + 23 38 5 30 201 321 10 + 24 38 15 10 0 914 10 + 25 35 5 20 784 904 10 + 26 95 30 30 0 891 10 + 27 95 35 20 146 266 10 + 28 92 30 10 0 894 10 + 29 90 35 10 0 897 10 + 30 88 30 10 246 366 10 + 31 88 35 20 0 899 10 + 32 87 30 10 0 898 10 + 33 85 25 10 80 200 10 + 34 85 35 30 0 902 10 + 35 67 85 20 657 777 10 + 36 65 85 40 43 163 10 + 37 65 82 10 0 909 10 + 38 62 80 30 278 398 10 + 39 60 80 10 64 184 10 + 40 60 85 30 329 449 10 + 41 58 75 20 376 496 10 + 42 55 80 10 33 153 10 + 43 55 85 20 0 911 10 + 44 55 82 10 217 337 10 + 45 20 82 10 37 157 10 + 46 18 80 10 0 912 10 + 47 2 45 10 0 911 10 + 48 42 5 10 0 904 10 + 49 42 12 10 440 560 10 + 50 72 35 30 0 914 10 + 51 55 20 19 0 916 10 + 52 25 30 3 0 925 10 + 53 20 50 5 375 495 10 + 54 55 60 16 0 931 10 + 55 30 60 16 599 719 10 + 56 50 35 19 557 677 10 + 57 30 25 23 0 923 10 + 58 15 10 20 782 902 10 + 59 10 20 19 0 907 10 + 60 15 60 17 0 923 10 + 61 45 65 9 0 934 10 + 62 65 35 3 167 287 10 + 63 65 20 6 0 910 10 + 64 45 30 17 191 311 10 + 65 35 40 16 11 131 10 + 66 41 37 16 566 686 10 + 67 64 42 9 268 388 10 + 68 40 60 21 612 732 10 + 69 31 52 27 157 277 10 + 70 35 69 23 810 930 10 + 71 65 55 14 0 924 10 + 72 63 65 8 0 922 10 + 73 2 60 5 0 910 10 + 74 20 20 8 645 765 10 + 75 5 5 16 0 892 10 + 76 60 12 31 268 388 10 + 77 23 3 7 764 884 10 + 78 8 56 27 365 485 10 + 79 6 68 30 352 472 10 + 80 47 47 13 822 942 10 + 81 49 58 10 0 937 10 + 82 27 43 9 0 935 10 + 83 37 31 14 0 930 10 + 84 57 29 18 395 515 10 + 85 63 23 2 0 914 10 + 86 21 24 28 0 917 10 + 87 12 24 13 359 479 10 + 88 24 58 19 260 380 10 + 89 67 5 25 0 897 10 + 90 37 47 6 0 945 10 + 91 49 42 13 0 937 10 + 92 53 43 14 14 134 10 + 93 61 52 3 808 928 10 + 94 57 48 23 0 932 10 + 95 56 37 6 0 929 10 + 96 55 54 26 0 934 10 + 97 4 18 35 0 901 10 + 98 26 52 9 0 935 10 + 99 26 35 15 308 428 10 + 100 31 67 3 810 930 10 diff --git a/jsprit-instances/instances/solomon/RC204.txt b/jsprit-instances/instances/solomon/RC204.txt new file mode 100644 index 00000000..dbf13f07 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC204.txt @@ -0,0 +1,110 @@ +RC204 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 0 911 10 + 2 22 75 30 0 919 10 + 3 22 85 10 0 910 10 + 4 20 80 40 644 764 10 + 5 20 85 20 0 909 10 + 6 18 75 20 0 916 10 + 7 15 75 20 0 914 10 + 8 15 80 10 367 487 10 + 9 10 35 20 371 491 10 + 10 10 40 30 0 918 10 + 11 8 40 40 195 315 10 + 12 8 45 20 0 917 10 + 13 5 35 10 653 773 10 + 14 5 45 10 0 914 10 + 15 2 40 20 174 294 10 + 16 0 40 20 0 908 10 + 17 0 45 20 0 909 10 + 18 44 5 20 0 904 10 + 19 42 10 40 0 909 10 + 20 42 15 10 0 914 10 + 21 40 5 10 0 905 10 + 22 40 15 40 0 915 10 + 23 38 5 30 201 321 10 + 24 38 15 10 0 914 10 + 25 35 5 20 784 904 10 + 26 95 30 30 0 891 10 + 27 95 35 20 0 892 10 + 28 92 30 10 0 894 10 + 29 90 35 10 0 897 10 + 30 88 30 10 0 898 10 + 31 88 35 20 0 899 10 + 32 87 30 10 0 898 10 + 33 85 25 10 0 898 10 + 34 85 35 30 0 902 10 + 35 67 85 20 0 905 10 + 36 65 85 40 0 906 10 + 37 65 82 10 0 909 10 + 38 62 80 30 278 398 10 + 39 60 80 10 0 913 10 + 40 60 85 30 0 909 10 + 41 58 75 20 0 919 10 + 42 55 80 10 0 916 10 + 43 55 85 20 0 911 10 + 44 55 82 10 217 337 10 + 45 20 82 10 0 912 10 + 46 18 80 10 0 912 10 + 47 2 45 10 0 911 10 + 48 42 5 10 0 904 10 + 49 42 12 10 0 911 10 + 50 72 35 30 0 914 10 + 51 55 20 19 0 916 10 + 52 25 30 3 0 925 10 + 53 20 50 5 375 495 10 + 54 55 60 16 0 931 10 + 55 30 60 16 599 719 10 + 56 50 35 19 0 931 10 + 57 30 25 23 0 923 10 + 58 15 10 20 782 902 10 + 59 10 20 19 0 907 10 + 60 15 60 17 0 923 10 + 61 45 65 9 0 934 10 + 62 65 35 3 167 287 10 + 63 65 20 6 0 910 10 + 64 45 30 17 0 929 10 + 65 35 40 16 0 938 10 + 66 41 37 16 0 936 10 + 67 64 42 9 268 388 10 + 68 40 60 21 0 940 10 + 69 31 52 27 157 277 10 + 70 35 69 23 0 930 10 + 71 65 55 14 0 924 10 + 72 63 65 8 0 922 10 + 73 2 60 5 0 910 10 + 74 20 20 8 645 765 10 + 75 5 5 16 0 892 10 + 76 60 12 31 268 388 10 + 77 23 3 7 764 884 10 + 78 8 56 27 0 917 10 + 79 6 68 30 352 472 10 + 80 47 47 13 0 942 10 + 81 49 58 10 0 937 10 + 82 27 43 9 0 935 10 + 83 37 31 14 0 930 10 + 84 57 29 18 395 515 10 + 85 63 23 2 0 914 10 + 86 21 24 28 0 917 10 + 87 12 24 13 359 479 10 + 88 24 58 19 0 932 10 + 89 67 5 25 0 897 10 + 90 37 47 6 0 945 10 + 91 49 42 13 0 937 10 + 92 53 43 14 14 134 10 + 93 61 52 3 0 928 10 + 94 57 48 23 0 932 10 + 95 56 37 6 0 929 10 + 96 55 54 26 0 934 10 + 97 4 18 35 0 901 10 + 98 26 52 9 0 935 10 + 99 26 35 15 308 428 10 + 100 31 67 3 810 930 10 diff --git a/jsprit-instances/instances/solomon/RC205.txt b/jsprit-instances/instances/solomon/RC205.txt new file mode 100644 index 00000000..73fd4d3d --- /dev/null +++ b/jsprit-instances/instances/solomon/RC205.txt @@ -0,0 +1,110 @@ +RC205 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 431 911 10 + 2 22 75 30 30 510 10 + 3 22 85 10 291 771 10 + 4 20 80 40 674 734 10 + 5 20 85 20 40 520 10 + 6 18 75 20 393 502 10 + 7 15 75 20 120 600 10 + 8 15 80 10 397 457 10 + 9 10 35 20 401 461 10 + 10 10 40 30 535 622 10 + 11 8 40 40 225 285 10 + 12 8 45 20 43 523 10 + 13 5 35 10 683 743 10 + 14 5 45 10 35 366 10 + 15 2 40 20 204 264 10 + 16 0 40 20 204 425 10 + 17 0 45 20 698 827 10 + 18 44 5 20 306 483 10 + 19 42 10 40 199 428 10 + 20 42 15 10 494 699 10 + 21 40 5 10 45 525 10 + 22 40 15 40 383 486 10 + 23 38 5 30 231 291 10 + 24 38 15 10 609 872 10 + 25 35 5 20 821 881 10 + 26 95 30 30 349 829 10 + 27 95 35 20 138 273 10 + 28 92 30 10 78 339 10 + 29 90 35 10 132 375 10 + 30 88 30 10 252 359 10 + 31 88 35 20 50 530 10 + 32 87 30 10 562 799 10 + 33 85 25 10 71 208 10 + 34 85 35 30 307 787 10 + 35 67 85 20 655 778 10 + 36 65 85 40 43 186 10 + 37 65 82 10 377 857 10 + 38 62 80 30 308 368 10 + 39 60 80 10 46 201 10 + 40 60 85 30 339 438 10 + 41 58 75 20 377 494 10 + 42 55 80 10 33 166 10 + 43 55 85 20 531 736 10 + 44 55 82 10 247 307 10 + 45 20 82 10 37 177 10 + 46 18 80 10 432 665 10 + 47 2 45 10 38 322 10 + 48 42 5 10 424 904 10 + 49 42 12 10 460 539 10 + 50 72 35 30 327 807 10 + 51 55 20 19 273 498 10 + 52 25 30 3 25 505 10 + 53 20 50 5 405 465 10 + 54 55 60 16 554 767 10 + 55 30 60 16 629 689 10 + 56 50 35 19 560 673 10 + 57 30 25 23 342 571 10 + 58 15 10 20 842 902 10 + 59 10 20 19 42 522 10 + 60 15 60 17 623 884 10 + 61 45 65 9 214 421 10 + 62 65 35 3 197 257 10 + 63 65 20 6 39 316 10 + 64 45 30 17 191 310 10 + 65 35 40 16 11 140 10 + 66 41 37 16 570 681 10 + 67 64 42 9 298 358 10 + 68 40 60 21 613 730 10 + 69 31 52 27 187 247 10 + 70 35 69 23 780 930 10 + 71 65 55 14 191 410 10 + 72 63 65 8 27 507 10 + 73 2 60 5 240 451 10 + 74 20 20 8 675 735 10 + 75 5 5 16 57 537 10 + 76 60 12 31 298 358 10 + 77 23 3 7 794 854 10 + 78 8 56 27 366 483 10 + 79 6 68 30 382 442 10 + 80 47 47 13 817 942 10 + 81 49 58 10 332 497 10 + 82 27 43 9 14 494 10 + 83 37 31 14 19 499 10 + 84 57 29 18 425 485 10 + 85 63 23 2 164 644 10 + 86 21 24 28 310 507 10 + 87 12 24 13 389 449 10 + 88 24 58 19 262 377 10 + 89 67 5 25 611 897 10 + 90 37 47 6 311 526 10 + 91 49 42 13 457 937 10 + 92 53 43 14 14 74 10 + 93 61 52 3 789 928 10 + 94 57 48 23 212 692 10 + 95 56 37 6 20 500 10 + 96 55 54 26 382 862 10 + 97 4 18 35 516 697 10 + 98 26 52 9 14 494 10 + 99 26 35 15 338 398 10 + 100 31 67 3 870 930 10 diff --git a/jsprit-instances/instances/solomon/RC206.txt b/jsprit-instances/instances/solomon/RC206.txt new file mode 100644 index 00000000..be10c63b --- /dev/null +++ b/jsprit-instances/instances/solomon/RC206.txt @@ -0,0 +1,110 @@ +RC206 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 613 853 10 + 2 22 75 30 92 332 10 + 3 22 85 10 411 651 10 + 4 20 80 40 584 824 10 + 5 20 85 20 40 280 10 + 6 18 75 20 328 568 10 + 7 15 75 20 240 480 10 + 8 15 80 10 307 547 10 + 9 10 35 20 311 551 10 + 10 10 40 30 459 699 10 + 11 8 40 40 135 375 10 + 12 8 45 20 163 403 10 + 13 5 35 10 593 833 10 + 14 5 45 10 35 275 10 + 15 2 40 20 114 354 10 + 16 0 40 20 195 435 10 + 17 0 45 20 643 883 10 + 18 44 5 20 275 515 10 + 19 42 10 40 194 434 10 + 20 42 15 10 477 717 10 + 21 40 5 10 155 395 10 + 22 40 15 40 315 555 10 + 23 38 5 30 141 381 10 + 24 38 15 10 621 861 10 + 25 35 5 20 664 904 10 + 26 95 30 30 469 709 10 + 27 95 35 20 86 326 10 + 28 92 30 10 89 329 10 + 29 90 35 10 134 374 10 + 30 88 30 10 186 426 10 + 31 88 35 20 105 345 10 + 32 87 30 10 561 801 10 + 33 85 25 10 51 291 10 + 34 85 35 30 427 667 10 + 35 67 85 20 597 837 10 + 36 65 85 40 43 283 10 + 37 65 82 10 497 737 10 + 38 62 80 30 218 458 10 + 39 60 80 10 36 276 10 + 40 60 85 30 269 509 10 + 41 58 75 20 316 556 10 + 42 55 80 10 33 273 10 + 43 55 85 20 514 754 10 + 44 55 82 10 157 397 10 + 45 20 82 10 37 277 10 + 46 18 80 10 429 669 10 + 47 2 45 10 45 285 10 + 48 42 5 10 664 904 10 + 49 42 12 10 380 620 10 + 50 72 35 30 447 687 10 + 51 55 20 19 266 506 10 + 52 25 30 3 115 355 10 + 53 20 50 5 315 555 10 + 54 55 60 16 541 781 10 + 55 30 60 16 539 779 10 + 56 50 35 19 497 737 10 + 57 30 25 23 337 577 10 + 58 15 10 20 662 902 10 + 59 10 20 19 42 282 10 + 60 15 60 17 634 874 10 + 61 45 65 9 198 438 10 + 62 65 35 3 107 347 10 + 63 65 20 6 39 279 10 + 64 45 30 17 131 371 10 + 65 35 40 16 11 251 10 + 66 41 37 16 506 746 10 + 67 64 42 9 208 448 10 + 68 40 60 21 552 792 10 + 69 31 52 27 97 337 10 + 70 35 69 23 690 930 10 + 71 65 55 14 181 421 10 + 72 63 65 8 27 267 10 + 73 2 60 5 226 466 10 + 74 20 20 8 585 825 10 + 75 5 5 16 172 412 10 + 76 60 12 31 208 448 10 + 77 23 3 7 660 900 10 + 78 8 56 27 305 545 10 + 79 6 68 30 292 532 10 + 80 47 47 13 702 942 10 + 81 49 58 10 295 535 10 + 82 27 43 9 92 332 10 + 83 37 31 14 45 285 10 + 84 57 29 18 335 575 10 + 85 63 23 2 284 524 10 + 86 21 24 28 289 529 10 + 87 12 24 13 299 539 10 + 88 24 58 19 200 440 10 + 89 67 5 25 653 893 10 + 90 37 47 6 299 539 10 + 91 49 42 13 659 899 10 + 92 53 43 14 14 254 10 + 93 61 52 3 688 928 10 + 94 57 48 23 332 572 10 + 95 56 37 6 40 280 10 + 96 55 54 26 502 742 10 + 97 4 18 35 487 727 10 + 98 26 52 9 112 352 10 + 99 26 35 15 248 488 10 + 100 31 67 3 690 930 10 diff --git a/jsprit-instances/instances/solomon/RC207.txt b/jsprit-instances/instances/solomon/RC207.txt new file mode 100644 index 00000000..dc854c22 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC207.txt @@ -0,0 +1,110 @@ +RC207 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 591 874 10 + 2 22 75 30 73 350 10 + 3 22 85 10 473 588 10 + 4 20 80 40 418 913 10 + 5 20 85 20 40 390 10 + 6 18 75 20 249 646 10 + 7 15 75 20 281 438 10 + 8 15 80 10 272 581 10 + 9 10 35 20 236 625 10 + 10 10 40 30 470 687 10 + 11 8 40 40 33 510 10 + 12 8 45 20 166 399 10 + 13 5 35 10 359 911 10 + 14 5 45 10 35 457 10 + 15 2 40 20 39 538 10 + 16 0 40 20 214 415 10 + 17 0 45 20 359 909 10 + 18 44 5 20 338 451 10 + 19 42 10 40 205 422 10 + 20 42 15 10 511 682 10 + 21 40 5 10 158 391 10 + 22 40 15 40 263 606 10 + 23 38 5 30 45 522 10 + 24 38 15 10 598 883 10 + 25 35 5 20 348 904 10 + 26 95 30 30 509 668 10 + 27 95 35 20 57 664 10 + 28 92 30 10 68 349 10 + 29 90 35 10 131 376 10 + 30 88 30 10 114 497 10 + 31 88 35 20 102 347 10 + 32 87 30 10 564 797 10 + 33 85 25 10 51 673 10 + 34 85 35 30 462 631 10 + 35 67 85 20 396 905 10 + 36 65 85 40 43 712 10 + 37 65 82 10 530 703 10 + 38 62 80 30 131 544 10 + 39 60 80 10 36 800 10 + 40 60 85 30 233 544 10 + 41 58 75 20 207 664 10 + 42 55 80 10 33 624 10 + 43 55 85 20 549 718 10 + 44 55 82 10 62 491 10 + 45 20 82 10 37 677 10 + 46 18 80 10 435 662 10 + 47 2 45 10 38 366 10 + 48 42 5 10 636 904 10 + 49 42 12 10 423 576 10 + 50 72 35 30 471 662 10 + 51 55 20 19 281 490 10 + 52 25 30 3 109 360 10 + 53 20 50 5 284 585 10 + 54 55 60 16 568 753 10 + 55 30 60 16 421 896 10 + 56 50 35 19 404 829 10 + 57 30 25 23 347 566 10 + 58 15 10 20 380 902 10 + 59 10 20 19 42 466 10 + 60 15 60 17 613 894 10 + 61 45 65 9 230 405 10 + 62 65 35 3 29 587 10 + 63 65 20 6 39 353 10 + 64 45 30 17 20 497 10 + 65 35 40 16 11 570 10 + 66 41 37 16 423 828 10 + 67 64 42 9 112 543 10 + 68 40 60 21 441 902 10 + 69 31 52 27 9 532 10 + 70 35 69 23 211 930 10 + 71 65 55 14 201 400 10 + 72 63 65 8 27 382 10 + 73 2 60 5 255 436 10 + 74 20 20 8 427 913 10 + 75 5 5 16 183 400 10 + 76 60 12 31 162 493 10 + 77 23 3 7 360 900 10 + 78 8 56 27 195 654 10 + 79 6 68 30 258 565 10 + 80 47 47 13 426 942 10 + 81 49 58 10 369 460 10 + 82 27 43 9 85 338 10 + 83 37 31 14 19 326 10 + 84 57 29 18 304 605 10 + 85 63 23 2 318 489 10 + 86 21 24 28 332 485 10 + 87 12 24 13 365 472 10 + 88 24 58 19 100 539 10 + 89 67 5 25 565 897 10 + 90 37 47 6 324 513 10 + 91 49 42 13 651 906 10 + 92 53 43 14 14 669 10 + 93 61 52 3 298 928 10 + 94 57 48 23 385 518 10 + 95 56 37 6 20 299 10 + 96 55 54 26 538 705 10 + 97 4 18 35 546 667 10 + 98 26 52 9 109 354 10 + 99 26 35 15 170 565 10 + 100 31 67 3 262 930 10 diff --git a/jsprit-instances/instances/solomon/RC208.txt b/jsprit-instances/instances/solomon/RC208.txt new file mode 100644 index 00000000..19ba67e4 --- /dev/null +++ b/jsprit-instances/instances/solomon/RC208.txt @@ -0,0 +1,110 @@ +RC208 + +VEHICLE +NUMBER CAPACITY + 25 1000 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 960 0 + 1 25 85 20 388 911 10 + 2 22 75 30 30 546 10 + 3 22 85 10 353 708 10 + 4 20 80 40 425 913 10 + 5 20 85 20 40 630 10 + 6 18 75 20 228 667 10 + 7 15 75 20 161 558 10 + 8 15 80 10 229 624 10 + 9 10 35 20 213 648 10 + 10 10 40 30 404 753 10 + 11 8 40 40 33 511 10 + 12 8 45 20 46 519 10 + 13 5 35 10 395 911 10 + 14 5 45 10 35 697 10 + 15 2 40 20 39 528 10 + 16 0 40 20 94 535 10 + 17 0 45 20 394 909 10 + 18 44 5 20 218 571 10 + 19 42 10 40 85 542 10 + 20 42 15 10 391 802 10 + 21 40 5 10 45 517 10 + 22 40 15 40 229 640 10 + 23 38 5 30 45 523 10 + 24 38 15 10 389 914 10 + 25 35 5 20 386 904 10 + 26 95 30 30 389 788 10 + 27 95 35 20 57 600 10 + 28 92 30 10 55 575 10 + 29 90 35 10 52 536 10 + 30 88 30 10 90 521 10 + 31 88 35 20 50 534 10 + 32 87 30 10 425 898 10 + 33 85 25 10 51 602 10 + 34 85 35 30 342 751 10 + 35 67 85 20 410 905 10 + 36 65 85 40 43 617 10 + 37 65 82 10 410 823 10 + 38 62 80 30 114 561 10 + 39 60 80 10 36 658 10 + 40 60 85 30 191 586 10 + 41 58 75 20 201 670 10 + 42 55 80 10 33 568 10 + 43 55 85 20 429 838 10 + 44 55 82 10 49 504 10 + 45 20 82 10 37 597 10 + 46 18 80 10 315 782 10 + 47 2 45 10 38 606 10 + 48 42 5 10 396 904 10 + 49 42 12 10 341 658 10 + 50 72 35 30 351 782 10 + 51 55 20 19 161 610 10 + 52 25 30 3 25 516 10 + 53 20 50 5 239 630 10 + 54 55 60 16 448 873 10 + 55 30 60 16 420 897 10 + 56 50 35 19 390 843 10 + 57 30 25 23 227 686 10 + 58 15 10 20 401 902 10 + 59 10 20 19 42 706 10 + 60 15 60 17 401 923 10 + 61 45 65 9 110 525 10 + 62 65 35 3 29 548 10 + 63 65 20 6 39 593 10 + 64 45 30 17 20 498 10 + 65 35 40 16 11 530 10 + 66 41 37 16 404 847 10 + 67 64 42 9 100 555 10 + 68 40 60 21 436 907 10 + 69 31 52 27 9 510 10 + 70 35 69 23 330 930 10 + 71 65 55 14 81 520 10 + 72 63 65 8 27 622 10 + 73 2 60 5 135 556 10 + 74 20 20 8 430 913 10 + 75 5 5 16 63 520 10 + 76 60 12 31 125 530 10 + 77 23 3 7 390 900 10 + 78 8 56 27 190 659 10 + 79 6 68 30 215 608 10 + 80 47 47 13 444 942 10 + 81 49 58 10 249 580 10 + 82 27 43 9 14 506 10 + 83 37 31 14 19 566 10 + 84 57 29 18 259 650 10 + 85 63 23 2 198 609 10 + 86 21 24 28 212 605 10 + 87 12 24 13 272 565 10 + 88 24 58 19 90 549 10 + 89 67 5 25 325 897 10 + 90 37 47 6 204 633 10 + 91 49 42 13 442 937 10 + 92 53 43 14 14 581 10 + 93 61 52 3 373 928 10 + 94 57 48 23 265 638 10 + 95 56 37 6 20 539 10 + 96 55 54 26 418 825 10 + 97 4 18 35 426 787 10 + 98 26 52 9 14 499 10 + 99 26 35 15 149 586 10 + 100 31 67 3 356 930 10 diff --git a/jsprit-instances/instances/taillard/R_19.txt b/jsprit-instances/instances/taillard/R_19.txt new file mode 100644 index 00000000..b31ea1e4 --- /dev/null +++ b/jsprit-instances/instances/taillard/R_19.txt @@ -0,0 +1,4 @@ +Vehicle;Capacity;Fix;Var;#Veh +A;100;500;1.0;4 +B;200;1200;1.4;3 +C;300;2100;1.7;3 \ No newline at end of file diff --git a/jsprit-instances/instances/taillard/R_20.txt b/jsprit-instances/instances/taillard/R_20.txt new file mode 100644 index 00000000..54b845b6 --- /dev/null +++ b/jsprit-instances/instances/taillard/R_20.txt @@ -0,0 +1,4 @@ +Vehicle;Capacity;Fix;Var;#Veh +A;60;100;1.0;6 +B;140;300;1.7;4 +C;200;500;2.0;3 \ No newline at end of file diff --git a/jsprit-instances/license.txt b/jsprit-instances/license.txt new file mode 100644 index 00000000..f258a711 --- /dev/null +++ b/jsprit-instances/license.txt @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along + with this program; if not, write to the Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. \ No newline at end of file diff --git a/jsprit-instances/pom.xml b/jsprit-instances/pom.xml new file mode 100644 index 00000000..ddb20aeb --- /dev/null +++ b/jsprit-instances/pom.xml @@ -0,0 +1,42 @@ + + + + jsprit + jsprit-project + 0.0.1 + ../jsprit-project/pom.xml + + 4.0.0 + + jsprit-instances + jsprit-instances + + jar + + + + ${project.groupId} + jsprit-core + ${project.version} + + + diff --git a/jsprit-instances/src/main/java/readers/ChristophidesReader.java b/jsprit-instances/src/main/java/readers/ChristophidesReader.java new file mode 100644 index 00000000..146f154f --- /dev/null +++ b/jsprit-instances/src/main/java/readers/ChristophidesReader.java @@ -0,0 +1,156 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + + +import java.io.BufferedReader; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; + +import org.apache.log4j.Logger; + +import readers.ChristophidesReader; +import util.Coordinate; + +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; + +/** + * Reader that reads Christophides, Mingozzi and Toth instances. + * + *

Files and file-description can be found here. + * + * @author stefan schroeder + * + */ +public class ChristophidesReader { + + private static Logger logger = Logger.getLogger(ChristophidesReader.class); + + private final VehicleRoutingProblem.Builder vrpBuilder; + + private double coordProjectionFactor = 1; + + private int customerCounter = 1; + + /** + * Constructs the reader. + * + * @param vrpBuilder + */ + public ChristophidesReader(VehicleRoutingProblem.Builder vrpBuilder) { + super(); + this.vrpBuilder = vrpBuilder; + } + + /** + * Reads instance-file and memorizes vehicles, customers and so forth in + * {@link VehicleRoutingProblem.Builder}. + * + * @param fileName + */ + public void read(String fileName){ + vrpBuilder.setFleetSize(FleetSize.INFINITE); + BufferedReader reader = getReader(fileName); + int vehicleCapacity = 0; + double serviceTime = 0.0; + double endTime = Double.MAX_VALUE; + int counter = 0; + String line = null; + while((line = readLine(reader)) != null){ + line = line.replace("\r", ""); + line = line.trim(); + String[] tokens = line.split(" "); + if(counter == 0){ + vehicleCapacity = Integer.parseInt(tokens[1].trim()); + endTime = Double.parseDouble(tokens[2].trim()); + serviceTime = Double.parseDouble(tokens[3].trim()); + } + else if(counter == 1){ + String id = Integer.valueOf(counter).toString(); + Coordinate depotCoord = makeCoord(tokens[0].trim(),tokens[1].trim()); + VehicleType vehicleType = VehicleImpl.VehicleType.Builder.newInstance("christophidesType", vehicleCapacity). + setCostPerDistance(1.0).setFixedCost(100).build(); + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("christophidesVehicle").setLatestArrival(endTime).setLocationId(id).setLocationCoord(depotCoord). + setType(vehicleType).build(); + vrpBuilder.addVehicle(vehicle); + } + else{ + Coordinate customerCoord = makeCoord(tokens[0].trim(),tokens[1].trim()); + int demand = Integer.parseInt(tokens[2].trim()); + String customer = Integer.valueOf(customerCounter).toString(); + Service service = Service.Builder.newInstance(customer, demand).setServiceTime(serviceTime).setLocationId(customer).setCoord(customerCoord).build(); + vrpBuilder.addService(service); + customerCounter++; + } + counter++; + } + close(reader); + } + + public void setCoordProjectionFactor(double coordProjectionFactor) { + this.coordProjectionFactor = coordProjectionFactor; + } + + private void close(BufferedReader reader) { + try { + reader.close(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + } + } + + private String readLine(BufferedReader reader) { + try { + return reader.readLine(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + return null; + } + } + + private Coordinate makeCoord(String xString, String yString) { + double x = Double.parseDouble(xString); + double y = Double.parseDouble(yString); + return new Coordinate(x*coordProjectionFactor,y*coordProjectionFactor); + } + + private BufferedReader getReader(String solomonFile) { + BufferedReader reader = null; + try { + reader = new BufferedReader(new FileReader(solomonFile)); + } catch (FileNotFoundException e1) { + e1.printStackTrace(); + logger.error(e1); + System.exit(1); + } + return reader; + } +} diff --git a/jsprit-instances/src/main/java/readers/CordeauReader.java b/jsprit-instances/src/main/java/readers/CordeauReader.java new file mode 100644 index 00000000..e046724a --- /dev/null +++ b/jsprit-instances/src/main/java/readers/CordeauReader.java @@ -0,0 +1,172 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + + +import java.io.BufferedReader; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +import org.apache.log4j.Logger; + +import readers.CordeauReader; +import util.Coordinate; + +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleBuilder; +import basics.route.VehicleImpl.VehicleType; +import basics.Service; +import basics.VehicleRoutingProblem; + +/** + * Reader that reads instances developed by: + * + *

Cordeau, J.-F., Gendreau, M. and Laporte, G. (1997), A tabu search heuristic for periodic and multi-depot vehicle routing problems. + * Networks, 30: 105–119. doi: 10.1002/(SICI)1097-0037(199709)30:2<105::AID-NET5>3.0.CO;2-G + * + *

Files and file-description can be found here. + * + * @author stefan schroeder + * + */ +public class CordeauReader { + + private static Logger logger = Logger.getLogger(CordeauReader.class); + + private final VehicleRoutingProblem.Builder vrpBuilder; + + private double coordProjectionFactor = 1; + + public CordeauReader(VehicleRoutingProblem.Builder vrpBuilder) { + super(); + this.vrpBuilder = vrpBuilder; + } + + public void read(String fileName){ + vrpBuilder.setFleetSize(FleetSize.FINITE); + BufferedReader reader = getReader(fileName); + int vrpType; + int nOfDepots = 0; + int nOfCustomers = 0; + int nOfVehiclesAtEachDepot = 0; + + int counter = 0; + String line = null; + List> vehiclesAtDepot = new ArrayList>(); + int depotCounter = 0; + while((line = readLine(reader)) != null){ + line = line.replace("\r", ""); + line = line.trim(); + String[] tokens = line.split("\\s+"); + if(counter == 0){ + vrpType = Integer.parseInt(tokens[0].trim()); + if(vrpType != 2) throw new IllegalStateException("expect vrpType to be equal to 2 and thus to be MDVRP"); + nOfVehiclesAtEachDepot = Integer.parseInt(tokens[1].trim()); + nOfCustomers = Integer.parseInt(tokens[2].trim()); + nOfDepots = Integer.parseInt(tokens[3].trim()); + } + else if(counter <= nOfDepots){ + String depot = Integer.valueOf(counter).toString(); + int duration = Integer.parseInt(tokens[0].trim()); + if(duration == 0) duration = 999999; + int capacity = Integer.parseInt(tokens[1].trim()); + VehicleType vehicleType = VehicleImpl.VehicleType.Builder.newInstance(counter + "_cordeauType", capacity).setCostPerDistance(1.0).setFixedCost(100).build(); + List builders = new ArrayList(); + for(int vehicleCounter=0;vehicleCounter vBuilders = vehiclesAtDepot.get(depotCounter); + for(VehicleBuilder vBuilder : vBuilders){ + vBuilder.setLocationCoord(depotCoord); + VehicleImpl vehicle = vBuilder.build(); + vrpBuilder.addVehicle(vehicle); + } + depotCounter++; + } + else{ + throw new IllegalStateException("there are more lines than expected in file."); + } + counter++; + } + close(reader); + } + + public void setCoordProjectionFactor(double coordProjectionFactor) { + this.coordProjectionFactor = coordProjectionFactor; + } + + private void close(BufferedReader reader) { + try { + reader.close(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + } + } + + private String readLine(BufferedReader reader) { + try { + return reader.readLine(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + return null; + } + } + + private Coordinate makeCoord(String xString, String yString) { + double x = Double.parseDouble(xString); + double y = Double.parseDouble(yString); + return new Coordinate(x*coordProjectionFactor,y*coordProjectionFactor); + } + + private BufferedReader getReader(String solomonFile) { + BufferedReader reader = null; + try { + reader = new BufferedReader(new FileReader(solomonFile)); + } catch (FileNotFoundException e1) { + e1.printStackTrace(); + logger.error(e1); + System.exit(1); + } + return reader; + } +} diff --git a/jsprit-instances/src/main/java/readers/FigliozziReader.java b/jsprit-instances/src/main/java/readers/FigliozziReader.java new file mode 100644 index 00000000..8583636e --- /dev/null +++ b/jsprit-instances/src/main/java/readers/FigliozziReader.java @@ -0,0 +1,148 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + +import java.util.List; + +import org.apache.log4j.Logger; + +import util.CrowFlyCosts; +import util.Locations; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.Builder; +import basics.costs.VehicleRoutingTransportCosts; +import basics.route.Driver; +import basics.route.Vehicle; + +public class FigliozziReader { + + public static class TDCosts implements VehicleRoutingTransportCosts { + + private static Logger log = Logger.getLogger(TDCosts.class); + + private List timeBins; + + private List speed; + + private CrowFlyCosts crowFly; + + public TDCosts(Locations locations, List timeBins, List speedValues) { + super(); + speed = speedValues; + this.timeBins = timeBins; + crowFly = new CrowFlyCosts(locations); + } + + @Override + public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + return 1.0*crowFly.getTransportCost(fromId, toId, departureTime, null, null) + + 1.0*getTransportTime(fromId,toId,departureTime, null, null); +// return getTransportTime(fromId, toId, departureTime, driver, vehicle); +// return crowFly.getTransportCost(fromId, toId, departureTime, null, null); + } + + @Override + public double getBackwardTransportCost(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { +// return crowFly.getTransportCost(fromId, toId, arrivalTime, null,null) + getBackwardTransportTime(fromId, toId, arrivalTime,null,null); + return getBackwardTransportTime(fromId, toId, arrivalTime, driver, vehicle); +// return crowFly.getTransportCost(fromId, toId, arrivalTime, null, null); + } + + + @Override + public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { + if(fromId.equals(toId)){ + return 0.0; + } + double totalTravelTime = 0.0; + double distanceToTravel = crowFly.getTransportCost(fromId, toId, departureTime, null, null); + double currentTime = departureTime; + for(int i=0;i maxReachableDistance){ + distanceToTravel = distanceToTravel - maxReachableDistance; + totalTravelTime += (timeThreshold-currentTime); + currentTime = timeThreshold; + continue; + } + else{ //<= maxReachableDistance + totalTravelTime += distanceToTravel/speed.get(i); + return totalTravelTime; + } + } + } + return Double.MAX_VALUE; + } + + + @Override + public double getBackwardTransportTime(String fromId, String toId,double arrivalTime, Driver driver, Vehicle vehicle) { + if(fromId.equals(toId)){ + return 0.0; + } + double totalTravelTime = 0.0; + double distanceToTravel = crowFly.getTransportCost(fromId, toId, arrivalTime, null, null); + double currentTime = arrivalTime; + for(int i=timeBins.size()-1;i>=0;i--){ + double nextLowerTimeThreshold; + if(i>0){ + nextLowerTimeThreshold = timeBins.get(i-1); + } + else{ + nextLowerTimeThreshold = 0; + } + if(currentTime > nextLowerTimeThreshold){ + double maxReachableDistance = (currentTime - nextLowerTimeThreshold)*speed.get(i); + if(distanceToTravel > maxReachableDistance){ + distanceToTravel = distanceToTravel - maxReachableDistance; + totalTravelTime += (currentTime-nextLowerTimeThreshold); + currentTime = nextLowerTimeThreshold; + continue; + } + else{ //<= maxReachableDistance + totalTravelTime += distanceToTravel/speed.get(i); + return totalTravelTime; + } + } + } + return Double.MAX_VALUE; + } + + + + } + + private VehicleRoutingProblem.Builder builder; + + public FigliozziReader(Builder builder) { + super(); + this.builder = builder; + } + + public void read(String instanceFile, String speedScenarioFile, String speedScenario){ + + + } + + +} diff --git a/jsprit-instances/src/main/java/readers/LiLim.java b/jsprit-instances/src/main/java/readers/LiLim.java new file mode 100644 index 00000000..4b843dfd --- /dev/null +++ b/jsprit-instances/src/main/java/readers/LiLim.java @@ -0,0 +1,223 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; +//package instances; +// +//import java.io.BufferedReader; +//import java.io.IOException; +//import java.util.ArrayList; +//import java.util.Collection; +//import java.util.HashMap; +//import java.util.Map; +// +//import org.apache.log4j.Level; +//import org.apache.log4j.Logger; +//import org.matsim.contrib.freight.vrp.algorithms.rr.RuinAndRecreate; +//import org.matsim.contrib.freight.vrp.basics.Job; +//import org.matsim.contrib.freight.vrp.basics.Shipment; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoutingProblem; +//import org.matsim.contrib.freight.vrp.basics.VrpBuilder; +//import org.matsim.contrib.freight.vrp.utils.Coordinate; +//import org.matsim.contrib.freight.vrp.utils.CrowFlyCosts; +//import org.matsim.contrib.freight.vrp.utils.Locations; +//import org.matsim.core.utils.io.IOUtils; +// +///** +// * test instances for the capacitated vrp with pickup and deliveries and time windows. +// * instances are from li and lim and can be found at: +// * http://www.top.sintef.no/vrp/benchmarks.html +// * @author stefan schroeder +// * +// */ +// +// +//public class LiLim { +// +// static class MyLocations implements Locations{ +// +// private Map locations = new HashMap(); +// +// public void addLocation(String id, Coordinate coord){ +// locations.put(id, coord); +// } +// +// @Override +// public Coordinate getCoord(String id) { +// return locations.get(id); +// } +// } +// +// static class CustomerData{ +// public double start; +// public double end; +// public double serviceTime; +// public CustomerData(double start, double end, double serviceTime) { +// super(); +// this.start = start; +// this.end = end; +// this.serviceTime = serviceTime; +// } +// } +// +// static class Relation{ +// public String from; +// public String to; +// public int demand; +// public Relation(String from, String to, int demand) { +// super(); +// this.from = from; +// this.to = to; +// this.demand = demand; +// } +// +// } +// +// private static Logger logger = Logger.getLogger(Christophides.class); +// +// private VrpBuilder vrpBuilder; +// +//// private Locations locations; +// +// private String fileNameOfInstance; +// +// private int vehicleCapacity; +// +// private String depotId; +// +// private Map data; +// +// private Collection relations; +// +// private String instanceName; +// public LiLim(String fileNameOfInstance, String instanceName) { +// this.fileNameOfInstance = fileNameOfInstance; +// this.instanceName = instanceName; +// data = new HashMap(); +// relations = new ArrayList(); +// } +// +// public static void main(String[] args) { +// Logger.getRootLogger().setLevel(Level.INFO); +// LiLim liLim = new LiLim("/Users/stefan/Documents/workspace/VehicleRouting/instances/cvrppdtw_lilim/pdp100/lc205.txt", "lc205"); +// liLim.run(); +// } +// +// public void run(){ +// MyLocations myLocations = new MyLocations(); +// Collection jobs = new ArrayList(); +// readLocationsAndJobs(myLocations); +// buildJobs(jobs); +// VrpBuilder vrpBuilder = new VrpBuilder(new CrowFlyCosts(myLocations)); +// for(Job j : jobs){ +// vrpBuilder.addJob(j); +// } +// for(int i=0;i<20;i++){ +// vrpBuilder.addVehicle(VrpUtils.createVehicle("" + (i+1), depotId, vehicleCapacity, "standard",100.0,1.0,1.0)); +// } +// RuinAndRecreate algo = createAlgo(vrpBuilder.build()); +// algo.run(); +// } +// +// private void buildJobs(Collection jobs) { +// Integer counter = 0; +// for(Relation rel : relations){ +// counter++; +// String from = rel.from; +// String to = rel.to; +// Shipment s = VrpUtils.createShipment(counter.toString(), from, to, rel.demand, +// VrpUtils.createTimeWindow(data.get(from).start, data.get(from).end), +// VrpUtils.createTimeWindow(data.get(to).start, data.get(to).end)); +// s.setPickupServiceTime(data.get(from).serviceTime); +// s.setDeliveryServiceTime(data.get(to).serviceTime); +// jobs.add(s); +// } +// +// } +// +// private RuinAndRecreate createAlgo(VehicleRoutingProblem vrp) { +//// PickupAndDeliveryTourWithTimeWindowsAlgoFactory factory = new PickupAndDeliveryTourWithTimeWindowsAlgoFactory(); +//// factory.setIterations(100); +//// factory.setWarmUp(10); +//// RuinAndRecreateChartListener chartListener = new RuinAndRecreateChartListener(); +//// chartListener.setFilename("vrp/liLim/"+instanceName+".png"); +//// RuinAndRecreateReport report = new RuinAndRecreateReport(); +//// factory.addRuinAndRecreateListener(chartListener); +//// factory.addRuinAndRecreateListener(report); +//// return factory.createAlgorithm(vrp); +// return null; +// } +// +// private void readLocationsAndJobs(MyLocations locs) { +// BufferedReader reader = IOUtils.getBufferedReader(fileNameOfInstance); +// String line = null; +// boolean firstLine = true; +// try { +// while((line = reader.readLine()) != null){ +// line = line.replace("\r", ""); +// line = line.trim(); +// String[] tokens = line.split("\t"); +// if(firstLine){ +// int vehicleCapacity = getInt(tokens[1]); +// this.vehicleCapacity = vehicleCapacity; +// firstLine = false; +// continue; +// } +// else{ +// String customerId = tokens[0]; +// Coordinate coord = makeCoord(tokens[1], tokens[2]); +// if(customerId.equals("0")){ +// depotId = customerId; +// } +// int demand = getInt(tokens[3]); +// double startTimeWindow = getDouble(tokens[4]); +// double endTimeWindow = getDouble(tokens[5]); +// double serviceTime = getDouble(tokens[6]); +// locs.addLocation(customerId, coord); +// data.put(customerId, new CustomerData(startTimeWindow,endTimeWindow,serviceTime)); +// if(demand > 0){ +// relations.add(new Relation(customerId,tokens[8],demand)); +// } +// } +// } +// reader.close(); +// } catch (IOException e) { +// // TODO Auto-generated catch block +// e.printStackTrace(); +// } +// +// } +// +// private Coordinate makeCoord(String xString, String yString) { +// double x = Double.parseDouble(xString); +// double y = Double.parseDouble(yString); +// return new Coordinate(x,y); +// } +// +// private double getDouble(String string) { +// return Double.parseDouble(string); +// } +// +// private int getInt(String string) { +// return Integer.parseInt(string); +// } +// +// +//} diff --git a/jsprit-instances/src/main/java/readers/LuiShenReader.java b/jsprit-instances/src/main/java/readers/LuiShenReader.java new file mode 100644 index 00000000..45564983 --- /dev/null +++ b/jsprit-instances/src/main/java/readers/LuiShenReader.java @@ -0,0 +1,194 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + + +import java.io.BufferedReader; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; + +import org.apache.log4j.Logger; + +import readers.LuiShenReader; +import util.Coordinate; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.TimeWindow; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; + +public class LuiShenReader { + + private static Logger logger = Logger.getLogger(LuiShenReader.class); + + private final VehicleRoutingProblem.Builder vrpBuilder; + + private double coordProjectionFactor = 1; + + public LuiShenReader(VehicleRoutingProblem.Builder vrpBuilder) { + super(); + this.vrpBuilder = vrpBuilder; + this.vrpBuilder.setFleetComposition(FleetComposition.HETEROGENEOUS); + } + + /** + * Reads input files to build luiShen problem. + * + *

The instance-file is a solomon file. The vehicle-file is a + * txt-file that has the following columns: + *

Vehicle;Capacity;Cost_a;Cost_b;Cost_c + *

Concrete vehicleType: + *

A;100;300;60;30 + * + *

In the example above, the vehicle-type with typeId A has + * a capacity of 100, and fixed costs of 100 in cost scenario "a", + * 300 in "b" and 30 in "c". + + * @param instanceFile is a solomon-instance-file + * @param vehicleFile + * @param costScenario is either "a", "b" or "c" + */ + public void read(String instanceFile, String vehicleFile, String costScenario){ + vrpBuilder.setFleetSize(FleetSize.INFINITE); + BufferedReader reader = getReader(instanceFile); + int counter = 0; + String line = null; + while((line = readLine(reader)) != null){ + line = line.replace("\r", ""); + line = line.trim(); + String[] tokens = line.split(" +"); + counter++; + if(counter > 9){ + Coordinate coord = makeCoord(tokens[1],tokens[2]); + String customerId = tokens[0]; + int demand = Integer.parseInt(tokens[3]); + double start = Double.parseDouble(tokens[4])*coordProjectionFactor ; + double end = Double.parseDouble(tokens[5])*coordProjectionFactor; + double serviceTime = Double.parseDouble(tokens[6])*coordProjectionFactor; + if(counter == 10){ + createVehicles(vehicleFile,costScenario,customerId,coord,start,end); + } + else{ + Service service = Service.Builder.newInstance("" + counter, demand).setCoord(coord).setLocationId(customerId).setServiceTime(serviceTime) + .setTimeWindow(TimeWindow.newInstance(start, end)).build(); + vrpBuilder.addService(service); + } + } + } + close(reader); + } + + private void createVehicles(String vehicleFileName, String costScenario, String locationId, Coordinate coord, double start, double end) { + BufferedReader reader = getReader(vehicleFileName); + + int costScenarioColumn = getCostScenarioColumn(costScenario); + int vehicleIdColumn = 0; + int capacityColumn = 1; + + + + boolean firstLine = true; + String line = null; + while((line = readLine(reader)) != null){ + if(firstLine){ + firstLine = false; + continue; + } + String[] tokens = line.split(";"); + String vehicleId = tokens[vehicleIdColumn]; + int capacity = Integer.parseInt(tokens[capacityColumn]); + int fixCost = Integer.parseInt(tokens[costScenarioColumn]); + + VehicleType.Builder typeBuilder = VehicleImpl.VehicleType.Builder.newInstance(vehicleId, capacity); + typeBuilder.setFixedCost(fixCost).setCostPerDistance(1.0); + + VehicleType type = typeBuilder.build(); + + Vehicle reprVehicle = VehicleImpl.VehicleBuilder.newInstance(vehicleId).setEarliestStart(start).setLatestArrival(end). + setLocationId(locationId).setLocationCoord(coord).setType(type).build(); + + vrpBuilder.addVehicle(reprVehicle); + + } + close(reader); + } + + private int getCostScenarioColumn(String costScenario) { + if(costScenario.equals("a")){ + return 2; + } + else if(costScenario.equals("b")){ + return 3; + } + else if(costScenario.equals("c")){ + return 4; + } + throw new IllegalStateException("costScenario " + costScenario + " not known"); + } + + public void setCoordProjectionFactor(double coordProjectionFactor) { + this.coordProjectionFactor = coordProjectionFactor; + } + + private void close(BufferedReader reader) { + try { + reader.close(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + } + } + + private String readLine(BufferedReader reader) { + try { + return reader.readLine(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + return null; + } + } + + private Coordinate makeCoord(String xString, String yString) { + double x = Double.parseDouble(xString); + double y = Double.parseDouble(yString); + return new Coordinate(x*coordProjectionFactor,y*coordProjectionFactor); + } + + private BufferedReader getReader(String solomonFile) { + BufferedReader reader = null; + try { + reader = new BufferedReader(new FileReader(solomonFile)); + } catch (FileNotFoundException e1) { + e1.printStackTrace(); + logger.error(e1); + System.exit(1); + } + return reader; + } +} diff --git a/jsprit-instances/src/main/java/readers/SolomonReader.java b/jsprit-instances/src/main/java/readers/SolomonReader.java new file mode 100644 index 00000000..7fe24327 --- /dev/null +++ b/jsprit-instances/src/main/java/readers/SolomonReader.java @@ -0,0 +1,168 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + + +import java.io.BufferedReader; +import java.io.FileNotFoundException; +import java.io.FileReader; +import java.io.IOException; + +import org.apache.log4j.Logger; + +import readers.SolomonReader; +import util.Coordinate; + +import basics.route.TimeWindow; +import basics.route.Vehicle; +import basics.route.VehicleImpl; +import basics.route.VehicleImpl.VehicleType; +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; + +/** + * Reader that reads the well-known solomon-instances. + * + *

See: neo.org + * + * @author stefan + * + */ + +public class SolomonReader { + + /** + * @param costProjectionFactor the costProjectionFactor to set + */ + public void setVariableCostProjectionFactor(double costProjectionFactor) { + this.variableCostProjectionFactor = costProjectionFactor; + } + + private static Logger logger = Logger.getLogger(SolomonReader.class); + + private final VehicleRoutingProblem.Builder vrpBuilder; + + private double coordProjectionFactor = 1; + + private double timeProjectionFactor = 1; + + private double variableCostProjectionFactor = 1; + + public SolomonReader(VehicleRoutingProblem.Builder vrpBuilder) { + super(); + this.vrpBuilder = vrpBuilder; + } + + public void read(String solomonFile){ + vrpBuilder.setFleetSize(FleetSize.INFINITE); + BufferedReader reader = getReader(solomonFile); + int vehicleCapacity = 0; + + int counter = 0; + String line = null; + while((line = readLine(reader)) != null){ + line = line.replace("\r", ""); + line = line.trim(); + String[] tokens = line.split(" +"); + counter++; + if(counter == 5){ + vehicleCapacity = Integer.parseInt(tokens[1]); + continue; + } + if(counter > 9){ + Coordinate coord = makeCoord(tokens[1],tokens[2]); + String customerId = tokens[0]; + int demand = Integer.parseInt(tokens[3]); + double start = Double.parseDouble(tokens[4])*timeProjectionFactor; + double end = Double.parseDouble(tokens[5])*timeProjectionFactor; + double serviceTime = Double.parseDouble(tokens[6])*timeProjectionFactor; + if(counter == 10){ + VehicleType.Builder typeBuilder = VehicleImpl.VehicleType.Builder.newInstance("solomonType", vehicleCapacity); + typeBuilder.setCostPerDistance(1.0*variableCostProjectionFactor).setFixedCost(100); + + VehicleType vehicleType = typeBuilder.build(); + + Vehicle vehicle = VehicleImpl.VehicleBuilder.newInstance("solomonVehicle").setEarliestStart(start).setLatestArrival(end) + .setLocationId(customerId).setLocationCoord(coord).setType(vehicleType).build(); + +// vrpBuilder.addVehicleType(vehicleType); + vrpBuilder.addVehicle(vehicle); + + } + else{ + Service service = Service.Builder.newInstance(customerId, demand).setCoord(coord).setLocationId(customerId).setServiceTime(serviceTime) + .setTimeWindow(TimeWindow.newInstance(start, end)).build(); + vrpBuilder.addService(service); + } + } + } + close(reader); + } + + public void setCoordProjectionFactor(double coordProjectionFactor) { + this.coordProjectionFactor = coordProjectionFactor; + } + + private void close(BufferedReader reader) { + try { + reader.close(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + } + } + + private String readLine(BufferedReader reader) { + try { + return reader.readLine(); + } catch (IOException e) { + e.printStackTrace(); + logger.error(e); + System.exit(1); + return null; + } + } + + private Coordinate makeCoord(String xString, String yString) { + double x = Double.parseDouble(xString); + double y = Double.parseDouble(yString); + return new Coordinate(x*coordProjectionFactor,y*coordProjectionFactor); + } + + private BufferedReader getReader(String solomonFile) { + BufferedReader reader = null; + try { + reader = new BufferedReader(new FileReader(solomonFile)); + } catch (FileNotFoundException e1) { + e1.printStackTrace(); + logger.error(e1); + System.exit(1); + } + return reader; + } + + public void setTimeProjectionFactor(double timeProjection) { + this.timeProjectionFactor=timeProjection; + + } +} diff --git a/jsprit-instances/src/main/java/readers/Taillard.java b/jsprit-instances/src/main/java/readers/Taillard.java new file mode 100644 index 00000000..ee7df4a6 --- /dev/null +++ b/jsprit-instances/src/main/java/readers/Taillard.java @@ -0,0 +1,534 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; +//package instances; +// +//import java.io.BufferedReader; +//import java.io.IOException; +//import java.util.ArrayList; +//import java.util.Collection; +//import java.util.HashMap; +//import java.util.Map; +//import java.util.concurrent.ExecutorService; +//import java.util.concurrent.Executors; +//import java.util.concurrent.TimeUnit; +// +//import org.apache.log4j.Level; +//import org.apache.log4j.Logger; +//import org.matsim.contrib.freight.vrp.algorithms.rr.costCalculators.JobInsertionCalculator; +//import org.matsim.contrib.freight.vrp.algorithms.rr.costCalculators.RouteAgentFactory; +//import org.matsim.contrib.freight.vrp.algorithms.rr.listener.RuinAndRecreateReport; +//import org.matsim.contrib.freight.vrp.algorithms.rr.ruin.JobDistanceAvgCosts; +//import org.matsim.contrib.freight.vrp.algorithms.rr.ruin.RuinRadial; +//import org.matsim.contrib.freight.vrp.basics.Driver; +//import org.matsim.contrib.freight.vrp.basics.Job; +//import org.matsim.contrib.freight.vrp.basics.RouteAlgorithm; +//import org.matsim.contrib.freight.vrp.basics.RouteAlgorithm.VehicleSwitchedListener; +//import org.matsim.contrib.freight.vrp.basics.Service; +//import org.matsim.contrib.freight.vrp.basics.Tour; +//import org.matsim.contrib.freight.vrp.basics.TourActivity; +//import org.matsim.contrib.freight.vrp.basics.TourStateUpdater; +//import org.matsim.contrib.freight.vrp.basics.Vehicle; +//import org.matsim.contrib.freight.vrp.basics.VehicleFleetManager; +//import org.matsim.contrib.freight.vrp.basics.VehicleFleetManagerImpl; +//import org.matsim.contrib.freight.vrp.basics.VehicleImpl; +//import org.matsim.contrib.freight.vrp.basics.VehicleImpl.Type; +//import org.matsim.contrib.freight.vrp.basics.VehicleImpl.VehicleCostParams; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoute; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoute.VehicleRouteCostCalculator; +//import org.matsim.contrib.freight.vrp.basics.VehicleRouteCostFunction; +//import org.matsim.contrib.freight.vrp.basics.VehicleRouteCostFunctionFactory; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoutingCosts; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoutingProblem; +//import org.matsim.contrib.freight.vrp.basics.VehicleRoutingProblemSolution; +//import org.matsim.contrib.freight.vrp.basics.VrpBuilder; +//import org.matsim.contrib.freight.vrp.utils.Coordinate; +//import org.matsim.contrib.freight.vrp.utils.EuclideanDistanceCalculator; +//import org.matsim.contrib.freight.vrp.utils.Locations; +//import org.matsim.contrib.freight.vrp.utils.RouteUtils; +//import org.matsim.core.utils.io.IOUtils; +// +//import ruinFactories.RadialRuinFactory; +//import selectors.SelectBest; +//import selectors.SelectRandomly; +//import strategies.GendreauPostOpt; +//import strategies.RadialAndRandomRemoveBestInsert; +//import vrp.SearchStrategy; +//import vrp.SearchStrategyManager; +//import vrp.SearchStrategyModule; +//import vrp.VehicleRoutingMetaAlgorithm; +//import acceptors.AcceptNewRemoveWorst; +//import basics.VehicleRouteFactoryImpl; +//import basics.costcalculators.AuxilliaryCostCalculator; +//import basics.costcalculators.CalculatesActivityInsertion; +//import basics.costcalculators.CalculatesServiceInsertionConsideringFixCost; +//import basics.costcalculators.CalculatesServiceInsertionOnRouteLevel; +//import basics.costcalculators.CalculatesVehTypeDepServiceInsertion; +//import basics.inisolution.CreateInitialSolution; +//import basics.insertion.ConfigureFixCostCalculator; +//import basics.insertion.DepotDistance; +//import basics.insertion.ParRegretInsertion; +//import basics.insertion.RecreationBestInsertion; +// +///** +// * test instances for the capacitated vrp with time windows. instances are from solomon +// * and can be found at: +// * http://neo.lcc.uma.es/radi-aeb/WebVRP/ +// * @author stefan schroeder +// * +// */ +// +// +// +//public class Taillard { +// +// +// static class MyLocations implements Locations{ +// +// private Map locations = new HashMap(); +// +// public void addLocation(String id, Coordinate coord){ +// locations.put(id, coord); +// } +// +// @Override +// public Coordinate getCoord(String id) { +// return locations.get(id); +// } +// } +// +// public static final String VRPHE = "vrphe"; +// +// public static final String VFM = "vfm"; +// +// private static Logger logger = Logger.getLogger(Christophides.class); +// +// private String fileNameOfInstance; +// +// private String depotId; +// +// private String instanceName; +// +// private String vehicleFile; +// +// private String vehicleCostScenario; +// +// private String vrpType; +// +// private ResultWriter resultWriter; +// +// private RuinAndRecreateReport report; +// +// +// public Taillard(String fileNameOfInstance, String instanceName, String vehicleFileName, String vehicleCostScenario, String vrpType) { +// super(); +// this.fileNameOfInstance = fileNameOfInstance; +// this.instanceName = instanceName; +// this.vehicleFile = vehicleFileName; +// this.vehicleCostScenario = vehicleCostScenario; +// this.vrpType = vrpType; +// } +// +// public static void main(String[] args) throws IOException { +// System.out.println("start " + System.currentTimeMillis()); +// Logger.getRootLogger().setLevel(Level.INFO); +// +// int nOfProcessors = Runtime.getRuntime().availableProcessors(); +// logger.info("nOfProcessors: " + nOfProcessors); +// ExecutorService executor = Executors.newFixedThreadPool(nOfProcessors+2); +// +// ResultWriter resultWriter = new ResultWriter(); +//// String vrpType = "VFM"; +// String vrpType = VRPHE; +// String pblm_abbr = "R101"; +// String costScen = "R_19"; +// +// String problem = "100_" + pblm_abbr + "_LuiShen"; +// String problemFile = pblm_abbr + ".txt"; +// Taillard luiShen = new Taillard("/Users/stefan/Documents/Schroeder/Dissertation/vrpInstances/cvrptw_solomon/nOfCust100/"+problemFile, +// problem, "/Users/stefan/Documents/Schroeder/Dissertation/vrpInstances/vrphe_taillard/"+costScen+".txt", costScen, vrpType); +// luiShen.setResultWriter(resultWriter); +// luiShen.run(executor); +// +// System.out.println("finish " + System.currentTimeMillis()); +// resultWriter.write("output/taillard_"+ pblm_abbr + "_" + costScen + ".txt"); +// resultWriter.writeSolutions("output/taillard_solution_" + pblm_abbr + "_" + costScen + ".txt"); +// +// executor.shutdown(); +// try { +// executor.awaitTermination(10, TimeUnit.SECONDS); +// } catch (InterruptedException e) { +// // TODO Auto-generated catch block +// e.printStackTrace(); +// } +// } +// +// private static String getName(int i) { +// if(i<10){ +// return "0" + i; +// } +// else{ +// return "" + i; +// } +// } +// +// private void setResultWriter(ResultWriter resultWriter) { +// this.resultWriter = resultWriter; +// +// } +// +// public void run(ExecutorService executor){ +// +// final MyLocations myLocations = new MyLocations(); +// Collection jobs = new ArrayList(); +// final Map jobMap = readLocationsAndJobs(myLocations,jobs); +// +// VehicleRoutingCosts costs = new VehicleRoutingCosts() { +// +// @Override +// public double getBackwardTransportTime(String fromId, String toId, double arrivalTime, Driver driver, Vehicle vehicle) { +// return getTransportTime(fromId, toId, arrivalTime, null, null); +// } +// +// @Override +// public double getBackwardTransportCost(String fromId, String toId, double arrivalTime, Driver driver, Vehicle vehicle) { +// return getTransportCost(fromId, toId, arrivalTime, null, null); +// } +// +// @Override +// public double getTransportCost(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// double variableCost; +// if(vehicle == null){ +// variableCost = 1.0; +// } +// else{ +// variableCost = vehicle.getType().vehicleCostParams.perDistanceUnit; +// } +// return variableCost*EuclideanDistanceCalculator.calculateDistance(myLocations.getCoord(fromId), myLocations.getCoord(toId)); +// } +// +// @Override +// public double getTransportTime(String fromId, String toId, double departureTime, Driver driver, Vehicle vehicle) { +// return getTransportCost(fromId, toId, departureTime, driver, vehicle); +// } +// }; +// +// VrpBuilder vrpBuilder = new VrpBuilder(costs); +// for(Job j : jobs){ +// vrpBuilder.addJob(j); +// } +// createVehicles(vrpBuilder); +// VehicleRoutingProblem vrp = vrpBuilder.build(); +// +// VehicleRoutingMetaAlgorithm metaAlgorithm = new VehicleRoutingMetaAlgorithm(vrp); +// configure(metaAlgorithm,vrp,executor,myLocations); +// metaAlgorithm.run(); +// +// printSolutions(vrp); +// +// VehicleRoutingProblemSolution bestSolution = new SelectBest().selectSolution(vrp); +// +// resultWriter.addResult(instanceName+"_"+vehicleCostScenario , instanceName, RouteUtils.getNuOfActiveRoutes(bestSolution.getRoutes()), bestSolution.getCost()); +// resultWriter.addSolution(bestSolution); +// +// +// } +// +// private void printSolutions(VehicleRoutingProblem vrp) { +// for(VehicleRoutingProblemSolution s : vrp.getSolutions()){ +// System.out.println("total: " + s.getCost()); +// System.out.println("activeTours: " + RouteUtils.getNuOfActiveRoutes(s.getRoutes())); +// System.out.println(""); +// } +// +// } +// +// private void configure(VehicleRoutingMetaAlgorithm metaAlgorithm, final VehicleRoutingProblem vrp, ExecutorService executor, MyLocations myLocations) { +// VehicleRoute.VehicleRouteCostCalculator = new VehicleRouteCostCalculator() { +// +// @Override +// public double calculate(Tour tour, Vehicle vehicle, Driver driver) { +//// return vehicle.getType().vehicleCostParams.fix + tour.getCost(); +// return tour.getCost(); +// } +// +// }; +// +//// final VehicleFleetManager vehicleFleetManager = new InfiniteVehicles(vrp.getVehicles()); +// final VehicleFleetManager vehicleFleetManager = new VehicleFleetManagerImpl(vrp.getVehicles()); +// +// final VehicleRouteCostFunctionFactory costFuncFac = getFac(); +// +// AuxilliaryCostCalculator auxilliaryCostCalculator = new AuxilliaryCostCalculator(vrp.getCosts(), costFuncFac); +// CalculatesActivityInsertion actInsertion = new CalculatesActivityInsertion(auxilliaryCostCalculator,0,5); +//// CalculatesServiceInsertion standardServiceInsertion = new CalculatesServiceInsertion(actInsertion); +// CalculatesServiceInsertionOnRouteLevel standardServiceInsertion = new CalculatesServiceInsertionOnRouteLevel(actInsertion,vrp.getCosts(),costFuncFac); +// CalculatesServiceInsertionOnRouteLevel.MEMORYSIZE_FORPROMISING_INSERTIONPOSITIONS = 2; +// CalculatesServiceInsertionConsideringFixCost withFixCost = new CalculatesServiceInsertionConsideringFixCost(standardServiceInsertion); +// withFixCost.setWeightOfFixCost(0.0); +// +// final JobInsertionCalculator vehicleTypeDepInsertionCost = new CalculatesVehTypeDepServiceInsertion(vehicleFleetManager, standardServiceInsertion); +// +// final TourStateUpdater tourStateCalculator = new TourStateUpdater(vrp.getCosts(),costFuncFac); +// tourStateCalculator.setTimeWindowUpdate(false); +// +// RouteAgentFactory routeAgentFactory = new RouteAgentFactory(){ +// +// @Override +// public RouteAlgorithm createAgent(VehicleRoute route) { +// VehicleSwitchedListener switched = new VehicleSwitchedListener() { +// +// @Override +// public void vehicleSwitched(Vehicle oldVehicle, Vehicle newVehicle) { +// vehicleFleetManager.unlock(oldVehicle); +// vehicleFleetManager.lock(newVehicle); +// } +// +// }; +// RouteAlgorithmImpl agent = new RouteAlgorithmImpl(vehicleTypeDepInsertionCost, tourStateCalculator); +// agent.getListeners().add(switched); +// return agent; +// } +// +// }; +// +// ParRegretInsertion regretInsertion = new ParRegretInsertion(executor, routeAgentFactory); +// regretInsertion.getListener().add(new ConfigureFixCostCalculator(vrp, withFixCost)); +// regretInsertion.setJobDistance(new DepotDistance(myLocations, depotId)); +// regretInsertion.scoreParam_of_timeWindowLegth = 0.5; +// regretInsertion.scoreParam_of_distance = 0.2; +// regretInsertion.setVehicleRouteFactory(new VehicleRouteFactoryImpl(depotId)); +// +// +// RecreationBestInsertion bestInsertion = new RecreationBestInsertion(routeAgentFactory); +// bestInsertion.getListener().add(new ConfigureFixCostCalculator(vrp, withFixCost)); +// bestInsertion.setVehicleRouteFactory(new VehicleRouteFactoryImpl(depotId)); +// +//// for(int i=0;i<3;i++){ +// VehicleRoutingProblemSolution vrpSol = new CreateInitialSolution(bestInsertion).createInitialSolution(vrp); +// vrp.getSolutions().add(vrpSol); +//// } +// +// +// RadialAndRandomRemoveBestInsert smallNeighborHoodSearchModule = new RadialAndRandomRemoveBestInsert(vrp, vehicleFleetManager, routeAlgorithm); +// smallNeighborHoodSearchModule.setCalcConsideringFix(withFixCost); +// smallNeighborHoodSearchModule.setStateCalc(tourStateCalculator); +// smallNeighborHoodSearchModule.setInsertionStrategy(bestInsertion); +// smallNeighborHoodSearchModule.setAuxilliaryCostCalculator(auxilliaryCostCalculator); +// +// SearchStrategy smallNeighborHoodSearch = new SearchStrategy(new SelectRandomly(), new AcceptNewRemoveWorst()); +// +// smallNeighborHoodSearch.addModule(smallNeighborHoodSearchModule); +// +// GendreauPostOpt postOpt = new GendreauPostOpt(vrp, routeAgentFactory, +// (RuinRadial) new RadialRuinFactory(0.2, new JobDistanceAvgCosts(vrp.getCosts()), routeAgentFactory).createStrategy(vrp), +// bestInsertion); +// postOpt.setFleetManager(vehicleFleetManager); +// postOpt.setVehicleRouteFactory(new VehicleRouteFactoryImpl(depotId)); +// postOpt.setNuOfIterations(2000); +// postOpt.setShareOfJobsToRuin(0.18); +//// smallNeighborHoodSearch.addModule(postOpt); +// +// +//// SearchStrategy strat2 = new SearchStrategy(new SelectBest(), new AcceptNewRemoveWorst()); +//// GendreauPostOpt postOpt2 = new GendreauPostOpt(vrp, routeAgentFactory, +//// (RuinRadial) new RadialRuinFactory(0.2, new JobDistanceAvgCosts(vrp.getCosts()), routeAgentFactory).createStrategy(vrp), +//// bestInsertion); +//// postOpt2.setFleetManager(vehicleFleetManager); +//// postOpt2.setVehicleRouteFactory(new VehicleRouteFactoryImpl(depotId)); +//// postOpt2.setNuOfIterations(2000); +//// postOpt2.setShareOfJobsToRuin(0.1); +//// strat2.addModule(postOpt2); +// +// SearchStrategyModule solutionVerifier = new SearchStrategyModule() { +// +// @Override +// public VehicleRoutingProblemSolution runAndGetSolution(VehicleRoutingProblemSolution vrpSolution) { +// logger.info("verify solution"); +// if(SolutionVerifier.resultOfSolutionEqualsSumOfIndividualRouteCost(vrpSolution, vrp, costFuncFac,false)) return vrpSolution; +// throw new IllegalStateException("solution is not valid"); +// } +// }; +// smallNeighborHoodSearch.addModule(solutionVerifier); +// +// SearchStrategyManager strategyManager = new SearchStrategyManager(); +// strategyManager.addStrategy(smallNeighborHoodSearch, 1.0); +//// strategyManager.addStrategy(strat2, 0.3); +// +// metaAlgorithm.setSearchStrategyManager(strategyManager); +// metaAlgorithm.setNuOfIterations(20); +// VehicleRoutingProblem.SOLUTION_MEMORY = 4; +// +// +// } +// +// private VehicleRouteCostFunctionFactory getFac() { +// VehicleRouteCostFunctionFactory fac = new VehicleRouteCostFunctionFactory() { +// +// @Override +// public VehicleRouteCostFunction createCostFunction(Vehicle vehicle, Driver driver) { +// return new VehicleRouteCostFunction(){ +// +// double cost = 0.0; +// +// @Override +// public void handleActivity(TourActivity tourAct, double startTime, double endTime) { +// if(startTime > tourAct.getLatestOperationStartTime()){ +// cost += Double.MAX_VALUE; +// } +// } +// +// @Override +// public void handleLeg(TourActivity fromAct, TourActivity toAct, double depTime, double tpCost) { +// cost += tpCost; +// +// } +// +// @Override +// public double getCost() { +// return cost; +// } +// +// @Override +// public void finish() { +// +// +// } +// +// @Override +// public void reset() { +// +// } +// +// }; +// } +// }; +// return fac; +// } +// +// private void createVehicles(VrpBuilder vrpBuilder) { +// BufferedReader reader = IOUtils.getBufferedReader(vehicleFile); +// String line = null; +// int vehicleIdColumn = 0; +// int capacityColumn = 1; +// int fixColumn = 2; +// int varColumn = 3; +// int nOfVehiclesColumn = 4; +// boolean firstLine = true; +// try { +// while((line = reader.readLine()) != null){ +// if(firstLine){ +// firstLine = false; +// continue; +// } +// String[] tokens = line.split(";"); +// String vehicleId = tokens[vehicleIdColumn]; +// int capacity = Integer.parseInt(tokens[capacityColumn]); +// int fixCost = Integer.parseInt(tokens[fixColumn]); +// double var; +// if(vrpType.equals(VRPHE)){ +// var = Double.parseDouble(tokens[varColumn]); +// } +// else { +// var = 1.0; +// } +// int nOfVehicles = Integer.parseInt(tokens[nOfVehiclesColumn]); +// for(int i=0;i readLocationsAndJobs(MyLocations locations, Collection jobs){ +// BufferedReader reader = IOUtils.getBufferedReader(fileNameOfInstance); +// String line = null; +// int counter = 0; +// Map jobMap = new HashMap(); +// try { +// while((line = reader.readLine()) != null){ +// line = line.replace("\r", ""); +// line = line.trim(); +// String[] tokens = line.split(" +"); +// counter++; +// if(counter == 5){ +// int vehicleCap = Integer.parseInt(tokens[1]); +// continue; +// } +// +// if(counter > 9){ +// Coordinate coord = makeCoord(tokens[1],tokens[2]); +// double depotStart = 0.0; +// double depotEnd = Double.MAX_VALUE; +// String customerId = tokens[0]; +// locations.addLocation(customerId, coord); +// int demand = Integer.parseInt(tokens[3]); +// double start = Double.parseDouble(tokens[4]); +// double end = Double.parseDouble(tokens[5]); +// double serviceTime = Double.parseDouble(tokens[6]); +// if(counter == 10){ +// depotStart = start; +// depotEnd = end; +// depotId = tokens[0]; +// +// } +// else{ +// Service service = VrpUtils.createService("" + counter, customerId, demand, 0.0, 0.0, Double.MAX_VALUE); +//// Shipment shipment = VrpUtils.createShipment("" + counter, depotId, customerId, demand, +//// VrpUtils.createTimeWindow(depotStart, depotEnd), VrpUtils.createTimeWindow(start, end)); +//// shipment.setDeliveryServiceTime(serviceTime); +// jobs.add(service); +// jobMap.put(customerId, service); +//// jobs.add(shipment); +//// j +//// Shipment shipment = VrpUtils.createShipment("" + counter, depotId, customerId, demand, +//// VrpUtils.createTimeWindow(depotStart, depotEnd), VrpUtils.createTimeWindow(start, end)); +//// shipment.setDeliveryServiceTime(serviceTime); +//// jobs.add(shipment); +// } +// } +// } +// reader.close(); +// } catch (NumberFormatException e) { +// // TODO Auto-generated catch block +// e.printStackTrace(); +// } catch (IOException e) { +// // TODO Auto-generated catch block +// e.printStackTrace(); +// } +// return jobMap; +// } +// +// private Coordinate makeCoord(String xString, String yString) { +// double x = Double.parseDouble(xString); +// double y = Double.parseDouble(yString); +// return new Coordinate(x,y); +// } +// +//} diff --git a/jsprit-instances/src/test/java/readers/ChristophidesReaderTest.java b/jsprit-instances/src/test/java/readers/ChristophidesReaderTest.java new file mode 100644 index 00000000..d58963aa --- /dev/null +++ b/jsprit-instances/src/test/java/readers/ChristophidesReaderTest.java @@ -0,0 +1,101 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + +import static org.junit.Assert.assertEquals; + +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.Vehicle; + +public class ChristophidesReaderTest { + + @Test + public void whenReadingInstance_nuOfCustomersIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc1.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(50,vrp.getJobs().values().size()); + } + + @Test + public void whenReadingInstance_fleetSizeIsInfinite(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc1.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.INFINITE,vrp.getFleetSize()); + } + + @Test + public void whenReadingInstance_vehicleCapacitiesAreCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc1.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(160,v.getCapacity()); + } + } + + @Test + public void whenReadingInstance_vehicleLocationsAreCorrect_and_correspondToDepotLocation(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc1.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(30.0,v.getCoord().getX(),0.01); + assertEquals(40.0,v.getCoord().getY(),0.01); + } + } + + @Test + public void whenReadingInstance_vehicleDurationsAreCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc13.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(0.0,v.getEarliestDeparture(),0.01); + assertEquals(720.0,v.getLatestArrival()-v.getEarliestDeparture(),0.01); + } + } + + @Test + public void whenReadingInstance_demandOfCustomerOneIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc1.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(7,vrp.getJobs().get("1").getCapacityDemand()); + } + + @Test + public void whenReadingInstance_serviceDurationOfCustomerTwoIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new ChristophidesReader(builder).read(this.getClass().getClassLoader().getResource("vrpnc13.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(50.0,((Service)vrp.getJobs().get("2")).getServiceDuration(),0.1); + } + + + + +} diff --git a/jsprit-instances/src/test/java/readers/CordeauReaderTest.java b/jsprit-instances/src/test/java/readers/CordeauReaderTest.java new file mode 100644 index 00000000..d013eb59 --- /dev/null +++ b/jsprit-instances/src/test/java/readers/CordeauReaderTest.java @@ -0,0 +1,148 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; + +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.Vehicle; + +public class CordeauReaderTest { + + @Test + public void testCordeauReader(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + vrpBuilder.build(); + + } + + @Test + public void whenReadingInstance_fleetSizeIsFinite(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + assertEquals(FleetSize.FINITE, vrp.getFleetSize()); + } + + @Test + public void testNuOfVehicles(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + assertEquals(16,vrp.getVehicles().size()); + } + + @Test + public void whenReadingCordeauInstance_vehiclesHaveTheCorrectCapacity(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(80, v.getCapacity()); + } + } + + @Test + public void whenReadingCordeauInstance_vehiclesHaveTheCorrectDuration(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p08").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(0.0,v.getEarliestDeparture(),0.1); + assertEquals(310.0, v.getLatestArrival()-v.getEarliestDeparture(),0.1); + } + } + + @Test + public void whenReadingCustomersCordeauInstance_customerOneShouldHaveCorrectCoordinates(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + Service service = (Service) vrp.getJobs().get("1"); + assertEquals(37.0, service.getCoord().getX(), 0.1); + assertEquals(52.0, service.getCoord().getY(), 0.1); + } + + @Test + public void whenReadingCustomersCordeauInstance_customerTwoShouldHaveCorrectServiceDuration(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + Service service = (Service) vrp.getJobs().get("2"); + assertEquals(0.0, service.getServiceDuration(), 0.1); + } + + @Test + public void whenReadingCustomersCordeauInstance_customerThreeShouldHaveCorrectDemand(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + Service service = (Service) vrp.getJobs().get("3"); + assertEquals(16.0, service.getCapacityDemand(), 0.1); + } + + @Test + public void whenReadingCustomersCordeauInstance_customerFortySevenShouldHaveCorrectDemand(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + Service service = (Service) vrp.getJobs().get("47"); + assertEquals(25.0, service.getCapacityDemand(), 0.1); + } + + @Test + public void testLocationsAndCapOfVehicles(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + boolean capacityOk = true; + boolean loc1ok = false; + boolean loc2ok = false; + boolean loc3ok = false; + boolean loc4ok = false; + for(Vehicle v : vrp.getVehicles()){ + if(v.getCapacity() != 80) capacityOk = false; + if(v.getCoord().getX() == 20.0 && v.getCoord().getY() == 20.0) loc1ok = true; + if(v.getCoord().getX() == 30.0 && v.getCoord().getY() == 40.0) loc2ok = true; + if(v.getCoord().getX() == 50.0 && v.getCoord().getY() == 30.0) loc3ok = true; + if(v.getCoord().getX() == 60.0 && v.getCoord().getY() == 50.0) loc4ok = true; + } + assertTrue(capacityOk); + assertTrue(loc1ok); + assertTrue(loc2ok); + assertTrue(loc3ok); + assertTrue(loc4ok); + } + + @Test + public void testNuOfCustomers(){ + VehicleRoutingProblem.Builder vrpBuilder = VehicleRoutingProblem.newBuilderInstance(); + new CordeauReader(vrpBuilder).read(this.getClass().getClassLoader().getResource("p01").getPath()); + VehicleRoutingProblem vrp = vrpBuilder.build(); + assertEquals(50,vrp.getJobs().values().size()); + } +} diff --git a/jsprit-instances/src/test/java/readers/LuiShenReaderTest.java b/jsprit-instances/src/test/java/readers/LuiShenReaderTest.java new file mode 100644 index 00000000..880f8c68 --- /dev/null +++ b/jsprit-instances/src/test/java/readers/LuiShenReaderTest.java @@ -0,0 +1,70 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + +import static org.junit.Assert.assertEquals; + +import org.junit.Before; +import org.junit.Test; + +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetComposition; +import basics.VehicleRoutingProblem.FleetSize; + +public class LuiShenReaderTest { + + VehicleRoutingProblem vrp; + + + @Before + public void doBefore(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new LuiShenReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath(), + this.getClass().getClassLoader().getResource("C1_LuiShenVehicles.txt").getPath(), "a"); + vrp = builder.build(); + } + + @Test + public void testFleetCompostion(){ + assertEquals(FleetComposition.HETEROGENEOUS,vrp.getFleetComposition()); + } + + @Test + public void testFleetSize(){ + assertEquals(FleetSize.INFINITE,vrp.getFleetSize()); + } + + + @Test + public void testNuOfTypes(){ + assertEquals(3, vrp.getTypes().size()); + } + + @Test + public void testNuOfRepresentativeVehicles(){ + assertEquals(3, vrp.getVehicles().size()); + } + + @Test + public void testNuOfJobs(){ + assertEquals(100,vrp.getJobs().values().size()); + } +} diff --git a/jsprit-instances/src/test/java/readers/SolomonReaderTest.java b/jsprit-instances/src/test/java/readers/SolomonReaderTest.java new file mode 100644 index 00000000..c1145f8f --- /dev/null +++ b/jsprit-instances/src/test/java/readers/SolomonReaderTest.java @@ -0,0 +1,104 @@ +/******************************************************************************* + * Copyright (C) 2013 Stefan Schroeder + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + * + * Contributors: + * Stefan Schroeder - initial API and implementation + ******************************************************************************/ +package readers; + +import static org.junit.Assert.assertEquals; + +import org.junit.Test; + +import basics.Service; +import basics.VehicleRoutingProblem; +import basics.VehicleRoutingProblem.FleetSize; +import basics.route.Vehicle; + +public class SolomonReaderTest { + + @Test + public void whenReadingSolomonInstance_nuOfCustomersIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(100,vrp.getJobs().values().size()); + } + + @Test + public void whenReadingSolomonInstance_fleetSizeIsInfinite(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(FleetSize.INFINITE,vrp.getFleetSize()); + } + + @Test + public void whenReadingSolomonInstance_vehicleCapacitiesAreCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(200,v.getCapacity()); + } + } + + @Test + public void whenReadingSolomonInstance_vehicleLocationsAreCorrect_and_correspondToDepotLocation(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + for(Vehicle v : vrp.getVehicles()){ + assertEquals(40.0,v.getCoord().getX(),0.01); + assertEquals(50.0,v.getCoord().getY(),0.01); + } + } + + @Test + public void whenReadingSolomonInstance_demandOfCustomerOneIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(10,vrp.getJobs().get("1").getCapacityDemand()); + } + + @Test + public void whenReadingSolomonInstance_serviceDurationOfCustomerTwoIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(90,((Service)vrp.getJobs().get("2")).getServiceDuration(),0.1); + } + + @Test + public void whenReadingSolomonInstance_earliestServiceStartTimeOfCustomerSixtyTwoIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(262.0,((Service)vrp.getJobs().get("62")).getTimeWindow().getStart(),0.1); + } + + @Test + public void whenReadingSolomonInstance_latestServiceStartTimeOfCustomerEightySevenIsCorrect(){ + VehicleRoutingProblem.Builder builder = VehicleRoutingProblem.Builder.newInstance(); + new SolomonReader(builder).read(this.getClass().getClassLoader().getResource("C101_solomon.txt").getPath()); + VehicleRoutingProblem vrp = builder.build(); + assertEquals(144.0,((Service)vrp.getJobs().get("87")).getTimeWindow().getEnd(),0.1); + } + + +} diff --git a/jsprit-instances/src/test/resources/C101_solomon.txt b/jsprit-instances/src/test/resources/C101_solomon.txt new file mode 100644 index 00000000..ed6b1d7f --- /dev/null +++ b/jsprit-instances/src/test/resources/C101_solomon.txt @@ -0,0 +1,110 @@ +C101 + +VEHICLE +NUMBER CAPACITY + 25 200 + +CUSTOMER +CUST NO. XCOORD. YCOORD. DEMAND READY TIME DUE DATE SERVICE TIME + + 0 40 50 0 0 1236 0 + 1 45 68 10 912 967 90 + 2 45 70 30 825 870 90 + 3 42 66 10 65 146 90 + 4 42 68 10 727 782 90 + 5 42 65 10 15 67 90 + 6 40 69 20 621 702 90 + 7 40 66 20 170 225 90 + 8 38 68 20 255 324 90 + 9 38 70 10 534 605 90 + 10 35 66 10 357 410 90 + 11 35 69 10 448 505 90 + 12 25 85 20 652 721 90 + 13 22 75 30 30 92 90 + 14 22 85 10 567 620 90 + 15 20 80 40 384 429 90 + 16 20 85 40 475 528 90 + 17 18 75 20 99 148 90 + 18 15 75 20 179 254 90 + 19 15 80 10 278 345 90 + 20 30 50 10 10 73 90 + 21 30 52 20 914 965 90 + 22 28 52 20 812 883 90 + 23 28 55 10 732 777 90 + 24 25 50 10 65 144 90 + 25 25 52 40 169 224 90 + 26 25 55 10 622 701 90 + 27 23 52 10 261 316 90 + 28 23 55 20 546 593 90 + 29 20 50 10 358 405 90 + 30 20 55 10 449 504 90 + 31 10 35 20 200 237 90 + 32 10 40 30 31 100 90 + 33 8 40 40 87 158 90 + 34 8 45 20 751 816 90 + 35 5 35 10 283 344 90 + 36 5 45 10 665 716 90 + 37 2 40 20 383 434 90 + 38 0 40 30 479 522 90 + 39 0 45 20 567 624 90 + 40 35 30 10 264 321 90 + 41 35 32 10 166 235 90 + 42 33 32 20 68 149 90 + 43 33 35 10 16 80 90 + 44 32 30 10 359 412 90 + 45 30 30 10 541 600 90 + 46 30 32 30 448 509 90 + 47 30 35 10 1054 1127 90 + 48 28 30 10 632 693 90 + 49 28 35 10 1001 1066 90 + 50 26 32 10 815 880 90 + 51 25 30 10 725 786 90 + 52 25 35 10 912 969 90 + 53 44 5 20 286 347 90 + 54 42 10 40 186 257 90 + 55 42 15 10 95 158 90 + 56 40 5 30 385 436 90 + 57 40 15 40 35 87 90 + 58 38 5 30 471 534 90 + 59 38 15 10 651 740 90 + 60 35 5 20 562 629 90 + 61 50 30 10 531 610 90 + 62 50 35 20 262 317 90 + 63 50 40 50 171 218 90 + 64 48 30 10 632 693 90 + 65 48 40 10 76 129 90 + 66 47 35 10 826 875 90 + 67 47 40 10 12 77 90 + 68 45 30 10 734 777 90 + 69 45 35 10 916 969 90 + 70 95 30 30 387 456 90 + 71 95 35 20 293 360 90 + 72 53 30 10 450 505 90 + 73 92 30 10 478 551 90 + 74 53 35 50 353 412 90 + 75 45 65 20 997 1068 90 + 76 90 35 10 203 260 90 + 77 88 30 10 574 643 90 + 78 88 35 20 109 170 90 + 79 87 30 10 668 731 90 + 80 85 25 10 769 820 90 + 81 85 35 30 47 124 90 + 82 75 55 20 369 420 90 + 83 72 55 10 265 338 90 + 84 70 58 20 458 523 90 + 85 68 60 30 555 612 90 + 86 66 55 10 173 238 90 + 87 65 55 20 85 144 90 + 88 65 60 30 645 708 90 + 89 63 58 10 737 802 90 + 90 60 55 10 20 84 90 + 91 60 60 10 836 889 90 + 92 67 85 20 368 441 90 + 93 65 85 40 475 518 90 + 94 65 82 10 285 336 90 + 95 62 80 30 196 239 90 + 96 60 80 10 95 156 90 + 97 60 85 30 561 622 90 + 98 58 75 20 30 84 90 + 99 55 80 10 743 820 90 + 100 55 85 20 647 726 90 diff --git a/jsprit-instances/src/test/resources/C1_LuiShenVehicles.txt b/jsprit-instances/src/test/resources/C1_LuiShenVehicles.txt new file mode 100644 index 00000000..9342bf92 --- /dev/null +++ b/jsprit-instances/src/test/resources/C1_LuiShenVehicles.txt @@ -0,0 +1,4 @@ +Vehicle;Capacity;Cost_a;Cost_b;Cost_c +A;100;300;60;30 +B;200;800;160;80 +C;300;1350;270;135 diff --git a/jsprit-instances/src/test/resources/p01 b/jsprit-instances/src/test/resources/p01 new file mode 100644 index 00000000..59157571 --- /dev/null +++ b/jsprit-instances/src/test/resources/p01 @@ -0,0 +1,59 @@ +2 4 50 4 +0 80 +0 80 +0 80 +0 80 + 1 37 52 0 7 1 4 1 2 4 8 + 2 49 49 0 30 1 4 1 2 4 8 + 3 52 64 0 16 1 4 1 2 4 8 + 4 20 26 0 9 1 4 1 2 4 8 + 5 40 30 0 21 1 4 1 2 4 8 + 6 21 47 0 15 1 4 1 2 4 8 + 7 17 63 0 19 1 4 1 2 4 8 + 8 31 62 0 23 1 4 1 2 4 8 + 9 52 33 0 11 1 4 1 2 4 8 +10 51 21 0 5 1 4 1 2 4 8 +11 42 41 0 19 1 4 1 2 4 8 +12 31 32 0 29 1 4 1 2 4 8 +13 5 25 0 23 1 4 1 2 4 8 +14 12 42 0 21 1 4 1 2 4 8 +15 36 16 0 10 1 4 1 2 4 8 +16 52 41 0 15 1 4 1 2 4 8 +17 27 23 0 3 1 4 1 2 4 8 +18 17 33 0 41 1 4 1 2 4 8 +19 13 13 0 9 1 4 1 2 4 8 +20 57 58 0 28 1 4 1 2 4 8 +21 62 42 0 8 1 4 1 2 4 8 +22 42 57 0 8 1 4 1 2 4 8 +23 16 57 0 16 1 4 1 2 4 8 +24 8 52 0 10 1 4 1 2 4 8 +25 7 38 0 28 1 4 1 2 4 8 +26 27 68 0 7 1 4 1 2 4 8 +27 30 48 0 15 1 4 1 2 4 8 +28 43 67 0 14 1 4 1 2 4 8 +29 58 48 0 6 1 4 1 2 4 8 +30 58 27 0 19 1 4 1 2 4 8 +31 37 69 0 11 1 4 1 2 4 8 +32 38 46 0 12 1 4 1 2 4 8 +33 46 10 0 23 1 4 1 2 4 8 +34 61 33 0 26 1 4 1 2 4 8 +35 62 63 0 17 1 4 1 2 4 8 +36 63 69 0 6 1 4 1 2 4 8 +37 32 22 0 9 1 4 1 2 4 8 +38 45 35 0 15 1 4 1 2 4 8 +39 59 15 0 14 1 4 1 2 4 8 +40 5 6 0 7 1 4 1 2 4 8 +41 10 17 0 27 1 4 1 2 4 8 +42 21 10 0 13 1 4 1 2 4 8 +43 5 64 0 11 1 4 1 2 4 8 +44 30 15 0 16 1 4 1 2 4 8 +45 39 10 0 10 1 4 1 2 4 8 +46 32 39 0 5 1 4 1 2 4 8 +47 25 32 0 25 1 4 1 2 4 8 +48 25 55 0 17 1 4 1 2 4 8 +49 48 28 0 18 1 4 1 2 4 8 +50 56 37 0 10 1 4 1 2 4 8 +51 20 20 0 0 0 0 +52 30 40 0 0 0 0 +53 50 30 0 0 0 0 +54 60 50 0 0 0 0 diff --git a/jsprit-instances/src/test/resources/p08 b/jsprit-instances/src/test/resources/p08 new file mode 100644 index 00000000..e272d5d8 --- /dev/null +++ b/jsprit-instances/src/test/resources/p08 @@ -0,0 +1,254 @@ +2 14 249 2 +310 500 +310 500 + 1 -99 -97 0 6 1 2 1 2 + 2 -59 50 0 72 1 2 1 2 + 3 0 14 0 93 1 2 1 2 + 4 -17 -66 0 28 1 2 1 2 + 5 -69 -19 0 5 1 2 1 2 + 6 31 12 0 43 1 2 1 2 + 7 5 -41 0 1 1 2 1 2 + 8 -12 10 0 36 1 2 1 2 + 9 -64 70 0 53 1 2 1 2 + 10 -12 85 0 63 1 2 1 2 + 11 -18 64 0 25 1 2 1 2 + 12 -77 -16 0 50 1 2 1 2 + 13 -53 88 0 57 1 2 1 2 + 14 83 -24 0 1 1 2 1 2 + 15 24 41 0 66 1 2 1 2 + 16 17 21 0 37 1 2 1 2 + 17 42 96 0 51 1 2 1 2 + 18 -65 0 0 47 1 2 1 2 + 19 -47 -26 0 88 1 2 1 2 + 20 85 36 0 75 1 2 1 2 + 21 -35 -54 0 48 1 2 1 2 + 22 54 -21 0 40 1 2 1 2 + 23 64 -17 0 8 1 2 1 2 + 24 55 89 0 69 1 2 1 2 + 25 17 -25 0 93 1 2 1 2 + 26 -61 66 0 29 1 2 1 2 + 27 -61 26 0 5 1 2 1 2 + 28 17 -72 0 53 1 2 1 2 + 29 79 38 0 8 1 2 1 2 + 30 -62 -2 0 24 1 2 1 2 + 31 -90 -68 0 53 1 2 1 2 + 32 52 66 0 13 1 2 1 2 + 33 -54 -50 0 47 1 2 1 2 + 34 8 -84 0 57 1 2 1 2 + 35 37 -90 0 9 1 2 1 2 + 36 -83 49 0 74 1 2 1 2 + 37 35 -1 0 83 1 2 1 2 + 38 7 59 0 96 1 2 1 2 + 39 12 48 0 42 1 2 1 2 + 40 57 95 0 80 1 2 1 2 + 41 92 28 0 22 1 2 1 2 + 42 -3 97 0 56 1 2 1 2 + 43 -7 52 0 43 1 2 1 2 + 44 42 -15 0 12 1 2 1 2 + 45 77 -43 0 73 1 2 1 2 + 46 59 -49 0 32 1 2 1 2 + 47 25 91 0 8 1 2 1 2 + 48 69 -19 0 79 1 2 1 2 + 49 -82 -14 0 79 1 2 1 2 + 50 74 -70 0 4 1 2 1 2 + 51 69 59 0 14 1 2 1 2 + 52 29 33 0 17 1 2 1 2 + 53 -97 9 0 19 1 2 1 2 + 54 -58 9 0 44 1 2 1 2 + 55 28 93 0 5 1 2 1 2 + 56 7 73 0 37 1 2 1 2 + 57 -28 73 0 100 1 2 1 2 + 58 -76 55 0 62 1 2 1 2 + 59 41 42 0 90 1 2 1 2 + 60 92 40 0 57 1 2 1 2 + 61 -84 -29 0 44 1 2 1 2 + 62 -12 42 0 37 1 2 1 2 + 63 51 -45 0 80 1 2 1 2 + 64 -37 46 0 60 1 2 1 2 + 65 -97 35 0 95 1 2 1 2 + 66 14 89 0 56 1 2 1 2 + 67 60 58 0 56 1 2 1 2 + 68 -63 -75 0 9 1 2 1 2 + 69 -18 34 0 39 1 2 1 2 + 70 -46 -82 0 15 1 2 1 2 + 71 -86 -79 0 4 1 2 1 2 + 72 -43 -30 0 58 1 2 1 2 + 73 -44 7 0 73 1 2 1 2 + 74 -3 -20 0 5 1 2 1 2 + 75 36 41 0 12 1 2 1 2 + 76 -30 -94 0 3 1 2 1 2 + 77 79 -62 0 8 1 2 1 2 + 78 51 70 0 31 1 2 1 2 + 79 -61 -26 0 48 1 2 1 2 + 80 6 94 0 3 1 2 1 2 + 81 -19 -62 0 52 1 2 1 2 + 82 -20 51 0 99 1 2 1 2 + 83 -81 37 0 29 1 2 1 2 + 84 7 31 0 12 1 2 1 2 + 85 52 12 0 50 1 2 1 2 + 86 83 -91 0 98 1 2 1 2 + 87 -7 -92 0 4 1 2 1 2 + 88 82 -74 0 56 1 2 1 2 + 89 -70 85 0 24 1 2 1 2 + 90 -83 -30 0 33 1 2 1 2 + 91 71 -61 0 45 1 2 1 2 + 92 85 11 0 98 1 2 1 2 + 93 66 -48 0 4 1 2 1 2 + 94 78 -87 0 36 1 2 1 2 + 95 9 -79 0 72 1 2 1 2 + 96 -36 4 0 26 1 2 1 2 + 97 66 39 0 71 1 2 1 2 + 98 92 -17 0 84 1 2 1 2 + 99 -46 -79 0 21 1 2 1 2 +100 -30 -63 0 99 1 2 1 2 +101 -42 63 0 33 1 2 1 2 +102 20 42 0 84 1 2 1 2 +103 15 98 0 74 1 2 1 2 +104 1 -17 0 93 1 2 1 2 +105 64 20 0 25 1 2 1 2 +106 -96 85 0 39 1 2 1 2 +107 93 -29 0 42 1 2 1 2 +108 -40 -84 0 77 1 2 1 2 +109 86 35 0 68 1 2 1 2 +110 91 36 0 50 1 2 1 2 +111 62 -8 0 42 1 2 1 2 +112 -24 4 0 71 1 2 1 2 +113 11 96 0 85 1 2 1 2 +114 -53 62 0 78 1 2 1 2 +115 -28 -71 0 64 1 2 1 2 +116 7 -4 0 5 1 2 1 2 +117 95 -9 0 93 1 2 1 2 +118 -3 17 0 18 1 2 1 2 +119 53 -90 0 38 1 2 1 2 +120 58 -19 0 29 1 2 1 2 +121 -83 84 0 81 1 2 1 2 +122 -1 49 0 4 1 2 1 2 +123 -4 17 0 23 1 2 1 2 +124 -82 -3 0 11 1 2 1 2 +125 -43 47 0 86 1 2 1 2 +126 6 -6 0 2 1 2 1 2 +127 70 99 0 31 1 2 1 2 +128 68 -29 0 54 1 2 1 2 +129 -94 -30 0 87 1 2 1 2 +130 -94 -20 0 17 1 2 1 2 +131 -21 77 0 81 1 2 1 2 +132 64 37 0 72 1 2 1 2 +133 -70 -19 0 10 1 2 1 2 +134 88 65 0 50 1 2 1 2 +135 2 29 0 25 1 2 1 2 +136 33 57 0 71 1 2 1 2 +137 -70 6 0 85 1 2 1 2 +138 -38 -56 0 51 1 2 1 2 +139 -80 -95 0 29 1 2 1 2 +140 -5 -39 0 55 1 2 1 2 +141 8 -22 0 45 1 2 1 2 +142 -61 -76 0 100 1 2 1 2 +143 76 -22 0 38 1 2 1 2 +144 49 -71 0 11 1 2 1 2 +145 -30 -68 0 82 1 2 1 2 +146 1 34 0 50 1 2 1 2 +147 77 79 0 39 1 2 1 2 +148 -58 64 0 6 1 2 1 2 +149 82 -97 0 87 1 2 1 2 +150 -80 55 0 83 1 2 1 2 +151 81 -86 0 22 1 2 1 2 +152 39 -49 0 24 1 2 1 2 +153 -67 72 0 69 1 2 1 2 +154 -25 -89 0 97 1 2 1 2 +155 -44 -95 0 65 1 2 1 2 +156 32 -68 0 97 1 2 1 2 +157 -17 49 0 79 1 2 1 2 +158 93 49 0 79 1 2 1 2 +159 99 81 0 46 1 2 1 2 +160 10 -49 0 52 1 2 1 2 +161 63 -41 0 39 1 2 1 2 +162 38 39 0 94 1 2 1 2 +163 -28 39 0 97 1 2 1 2 +164 -2 -47 0 18 1 2 1 2 +165 38 8 0 3 1 2 1 2 +166 -42 -6 0 23 1 2 1 2 +167 -67 88 0 19 1 2 1 2 +168 19 93 0 40 1 2 1 2 +169 40 27 0 49 1 2 1 2 +170 -61 56 0 96 1 2 1 2 +171 43 33 0 58 1 2 1 2 +172 -18 -39 0 15 1 2 1 2 +173 -69 19 0 21 1 2 1 2 +174 75 -18 0 56 1 2 1 2 +175 31 85 0 67 1 2 1 2 +176 25 58 0 10 1 2 1 2 +177 -16 36 0 36 1 2 1 2 +178 91 15 0 84 1 2 1 2 +179 60 -39 0 59 1 2 1 2 +180 49 -47 0 85 1 2 1 2 +181 42 33 0 60 1 2 1 2 +182 16 -81 0 33 1 2 1 2 +183 -78 53 0 62 1 2 1 2 +184 53 -80 0 70 1 2 1 2 +185 -46 -26 0 79 1 2 1 2 +186 -25 -54 0 98 1 2 1 2 +187 69 -46 0 99 1 2 1 2 +188 0 -78 0 18 1 2 1 2 +189 -84 74 0 55 1 2 1 2 +190 -16 16 0 75 1 2 1 2 +191 -63 -14 0 94 1 2 1 2 +192 51 -77 0 89 1 2 1 2 +193 -39 61 0 13 1 2 1 2 +194 5 97 0 19 1 2 1 2 +195 -55 39 0 19 1 2 1 2 +196 70 -14 0 90 1 2 1 2 +197 0 95 0 35 1 2 1 2 +198 -45 7 0 76 1 2 1 2 +199 38 -24 0 3 1 2 1 2 +200 50 -37 0 11 1 2 1 2 +201 59 71 0 98 1 2 1 2 +202 -73 -96 0 92 1 2 1 2 +203 -29 72 0 1 1 2 1 2 +204 -47 12 0 2 1 2 1 2 +205 -88 -61 0 63 1 2 1 2 +206 -88 36 0 57 1 2 1 2 +207 -46 -3 0 50 1 2 1 2 +208 26 -37 0 19 1 2 1 2 +209 -39 -67 0 24 1 2 1 2 +210 92 27 0 14 1 2 1 2 +211 -80 -31 0 18 1 2 1 2 +212 93 -50 0 77 1 2 1 2 +213 -20 -5 0 28 1 2 1 2 +214 -22 73 0 72 1 2 1 2 +215 -4 -7 0 49 1 2 1 2 +216 54 -48 0 58 1 2 1 2 +217 -70 39 0 84 1 2 1 2 +218 54 -82 0 58 1 2 1 2 +219 29 41 0 41 1 2 1 2 +220 -87 51 0 98 1 2 1 2 +221 -96 -36 0 77 1 2 1 2 +222 49 8 0 57 1 2 1 2 +223 -5 54 0 39 1 2 1 2 +224 -26 43 0 99 1 2 1 2 +225 -11 60 0 83 1 2 1 2 +226 40 61 0 54 1 2 1 2 +227 82 35 0 86 1 2 1 2 +228 -92 12 0 2 1 2 1 2 +229 -93 -86 0 14 1 2 1 2 +230 -66 63 0 42 1 2 1 2 +231 -72 -87 0 14 1 2 1 2 +232 -57 -84 0 55 1 2 1 2 +233 23 52 0 2 1 2 1 2 +234 -56 -62 0 18 1 2 1 2 +235 -19 59 0 17 1 2 1 2 +236 63 -14 0 22 1 2 1 2 +237 -13 38 0 28 1 2 1 2 +238 -19 87 0 3 1 2 1 2 +239 44 -84 0 96 1 2 1 2 +240 98 -17 0 53 1 2 1 2 +241 -16 62 0 15 1 2 1 2 +242 3 66 0 36 1 2 1 2 +243 26 22 0 98 1 2 1 2 +244 -38 -81 0 78 1 2 1 2 +245 70 -80 0 92 1 2 1 2 +246 17 -35 0 65 1 2 1 2 +247 96 -83 0 64 1 2 1 2 +248 -77 80 0 43 1 2 1 2 +249 -14 44 0 50 1 2 1 2 +250 -33 33 0 0 0 0 +251 33 -33 0 0 0 0 diff --git a/jsprit-instances/src/test/resources/vrpnc1.txt b/jsprit-instances/src/test/resources/vrpnc1.txt new file mode 100644 index 00000000..92297dc3 --- /dev/null +++ b/jsprit-instances/src/test/resources/vrpnc1.txt @@ -0,0 +1,52 @@ + 50 160 999999 0 + 30 40 + 37 52 7 + 49 49 30 + 52 64 16 + 20 26 9 + 40 30 21 + 21 47 15 + 17 63 19 + 31 62 23 + 52 33 11 + 51 21 5 + 42 41 19 + 31 32 29 + 5 25 23 + 12 42 21 + 36 16 10 + 52 41 15 + 27 23 3 + 17 33 41 + 13 13 9 + 57 58 28 + 62 42 8 + 42 57 8 + 16 57 16 + 8 52 10 + 7 38 28 + 27 68 7 + 30 48 15 + 43 67 14 + 58 48 6 + 58 27 19 + 37 69 11 + 38 46 12 + 46 10 23 + 61 33 26 + 62 63 17 + 63 69 6 + 32 22 9 + 45 35 15 + 59 15 14 + 5 6 7 + 10 17 27 + 21 10 13 + 5 64 11 + 30 15 16 + 39 10 10 + 32 39 5 + 25 32 25 + 25 55 17 + 48 28 18 + 56 37 10 diff --git a/jsprit-instances/src/test/resources/vrpnc13.txt b/jsprit-instances/src/test/resources/vrpnc13.txt new file mode 100644 index 00000000..b3c8bfcd --- /dev/null +++ b/jsprit-instances/src/test/resources/vrpnc13.txt @@ -0,0 +1,122 @@ +120 200 720 50 + 10 45 + 25 1 25 + 25 3 7 + 31 5 13 + 32 5 6 + 31 7 14 + 32 9 5 + 34 9 11 + 46 9 19 + 35 7 5 + 34 6 15 + 35 5 15 + 47 6 17 + 40 5 13 + 39 3 12 + 36 3 18 + 73 6 13 + 73 8 18 + 24 36 12 + 76 6 17 + 76 10 4 + 76 13 7 + 78 3 12 + 78 9 13 + 79 3 8 + 79 5 16 + 79 11 15 + 82 3 6 + 82 7 5 + 90 15 9 + 84 3 11 + 84 5 10 + 84 9 3 + 85 1 7 + 87 5 2 + 85 8 4 + 87 7 4 + 86 41 18 + 86 44 14 + 86 46 12 + 85 55 17 + 89 43 20 + 89 46 14 + 89 52 16 + 92 42 10 + 92 52 9 + 94 42 11 + 94 44 7 + 94 48 13 + 96 42 5 + 99 46 4 + 99 50 21 + 83 80 13 + 83 83 11 + 85 81 12 + 85 85 14 + 85 89 10 + 87 80 8 + 87 86 16 + 90 77 19 + 90 88 5 + 93 82 17 + 93 84 7 + 93 89 16 + 94 86 14 + 95 80 17 + 99 89 13 + 37 83 17 + 50 80 13 + 35 85 14 + 35 87 16 + 44 86 7 + 46 89 13 + 46 83 9 + 46 87 11 + 46 89 35 + 48 83 5 + 50 85 28 + 50 88 7 + 54 86 3 + 54 90 10 + 10 35 7 + 10 40 12 + 18 30 11 + 17 35 10 + 16 38 8 + 14 40 11 + 15 42 21 + 11 42 4 + 18 40 15 + 21 39 16 + 20 40 4 + 18 41 16 + 20 44 7 + 22 44 10 + 16 45 9 + 20 45 11 + 25 45 17 + 30 55 12 + 20 50 11 + 22 51 7 + 18 49 9 + 16 48 11 + 20 55 12 + 18 53 7 + 14 50 8 + 15 51 6 + 16 54 5 + 28 33 12 + 33 38 13 + 30 50 7 + 13 40 7 + 15 36 8 + 18 31 11 + 25 37 13 + 30 46 11 + 25 52 10 + 16 33 7 + 25 35 4 + 5 40 20 + 5 50 13 diff --git a/jsprit-project/.project b/jsprit-project/.project new file mode 100644 index 00000000..98d5ee6a --- /dev/null +++ b/jsprit-project/.project @@ -0,0 +1,17 @@ + + + jsprit-project + + + + + + org.eclipse.m2e.core.maven2Builder + + + + + + org.eclipse.m2e.core.maven2Nature + + diff --git a/jsprit-project/.settings/org.eclipse.core.resources.prefs b/jsprit-project/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 00000000..99f26c02 --- /dev/null +++ b/jsprit-project/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/jsprit-project/.settings/org.eclipse.m2e.core.prefs b/jsprit-project/.settings/org.eclipse.m2e.core.prefs new file mode 100644 index 00000000..f897a7f1 --- /dev/null +++ b/jsprit-project/.settings/org.eclipse.m2e.core.prefs @@ -0,0 +1,4 @@ +activeProfiles= +eclipse.preferences.version=1 +resolveWorkspaceProjects=true +version=1 diff --git a/jsprit-project/pom.xml b/jsprit-project/pom.xml new file mode 100644 index 00000000..8b183d74 --- /dev/null +++ b/jsprit-project/pom.xml @@ -0,0 +1,288 @@ + + + 4.0.0 + + jsprit + jsprit-project + 0.0.1 + + pom + + jsprit + A toolkit to solve vehicle routing problems. + https://github.com/jsprit/jsprit + 2013 + + + + GNU General Public License, version 2 (GPL-2.0) + http://opensource.org/licenses/GPL-2.0 + + + + + + Stefan Schroeder + 4sschroeder@gmail.com + + + + + 3.0.4 + + + + scm:git:git://github.com/jsprit/jsprit.git + scm:git:https://github.com/jsprit/jsprit.git + http://github.com/jsprit/jsprit/tree/master + v0.0.1 + + + + github + https://github.com/jsprit/jsprit/issues + + + + + jsprit-snapshots + https://github.com/jsprit/mvn-rep/raw/master/snapshots + + + + jsprit-releases + https://github.com/jsprit/mvn-rep/raw/master/releases + + + + + + ../jsprit-core + ../jsprit-analysis + ../jsprit-examples + ../jsprit-instances + + + + 1.6 + UTF-8 + 4.10 + 1.9.5 + 1.2.15 + + + + src/main/java + src/test/java + target + target/classes + target/test-classes + ${artifactId}-${version} + + + src/main/resources + + + + + src/test/resources + + + + + org.eclipse.m2e + lifecycle-mapping + 1.0.0 + + + + + + org.apache.maven.plugins + maven-enforcer-plugin + [1.0.0,) + + enforce + + + + + + + + + + + + maven-enforcer-plugin + 1.1.1 + + + enforce-versions + initialize + + enforce + + + true + + + Some plugin features require a recent Maven runtime to work properly + Current version of Maven ${maven.version} required to build the project should be ${project.prerequisites.maven}, or higher! + [${project.prerequisites.maven},) + + + Current JDK version ${java.version} should be ${jdkVersion}, or higher! + ${jdkVersion} + + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + ${jdkVersion} + ${jdkVersion} + true + true + ${project.build.sourceEncoding} + + true + 128m + 512m + + 4000 + 100 + + + + + + org.apache.maven.plugins + maven-eclipse-plugin + 2.8 + + + + org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6 + + + + + + + org.apache.maven.plugins + maven-source-plugin + + + attach-sources + + jar + + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + + + attach-javadocs + + jar + + + + + + + org.apache.maven.plugins + maven-release-plugin + 2.4.1 + + v@{project.version} + + + + + + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 2.8.1 + + + + + + + + junit + junit + ${junit.version} + + + + org.mockito + mockito-all + ${mockito.version} + + + + + log4j + log4j + ${logger.version} + + + javax.mail + mail + + + javax.jms + jms + + + com.sun.jdmk + jmxtools + + + com.sun.jmx + jmxri + + + + + + + +