Package org.ddolib.examples.pdp
Class PDPAcsMain
java.lang.Object
org.ddolib.examples.pdp.PDPAcsMain
Single Vehicle Pick-up and Delivery Problem (PDP) with Acs.
Main class for solving the Pickup and Delivery Problem (PDP) using the
Anytime Column Search (ACS) algorithm.
This class demonstrates how to configure and run the ACS-based solver on an automatically generated PDP instance. The PDP consists of a set of pickup and delivery requests that must be scheduled while respecting precedence constraints and minimizing the total travel cost or time.
Execution details:
- A random PDP instance is generated using
PDPGenerator.genInstance(int, int, int, Random). - The problem is modeled through an
AcsModel, which defines:- the
Problemto solve (PDPProblem), - a fast lower bound via
PDPFastLowerBound, - and the search column width (here set to 30).
- the
- The solver is then executed using
Solvers.minimizeAcs(AcsModel, java.util.function.BiConsumer). - Results and statistics are printed to the standard output.
Usage example:
// Run from the command line (no arguments required)
java PDPAcsMain
// Sample output:
RemainingJobs [...]
----> currentTime 42
SearchStatistics{status=OPTIMAL, iterations=..., time=...}
Notes:
- The instance generation is controlled by a fixed random seed (
new Random(1)) for reproducibility. - This example is primarily meant for experimentation and demonstration of the ACS solver.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
PDPAcsMain
public PDPAcsMain()
-
-
Method Details
-
main
Entry point for the PDP ACS solver.Generates a random Pickup and Delivery Problem instance and solves it using the Adaptive Column Search (ACS) framework.
- Parameters:
args- optional command-line arguments (not used in this version)- Throws:
IOException- if an error occurs during instance generation or file access
-