Package org.ddolib.examples.mcp
Class MCPAstarMain
java.lang.Object
org.ddolib.examples.mcp.MCPAstarMain
Maximum Cut Problem (MCP) with AsTar.
Main class for solving the Maximum Cut Problem (MCP) using an A* search approach.
This class demonstrates how to set up an A* model for the MCP, run the search, and print the resulting solution and statistics.
The problem instance can be provided as a command-line argument. If no argument is provided,
a default instance located at data/MCP/mcp_5_2.txt is used.
The model uses MCPFastLowerBound to compute a fast lower bound of the solution quality,
and the Model framework handles the search process using the A* algorithm.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
MCPAstarMain
public MCPAstarMain()
-
-
Method Details
-
main
Entry point of the application.Initializes the MCP problem, builds an A* model, and runs the search to find a maximum cut. The resulting solution is printed incrementally via
SolutionPrinterand a finalSearchStatisticssummary is displayed.- Parameters:
args- optional command-line arguments; args[0] can specify the path to an MCP instance file- Throws:
IOException- if the instance file cannot be read
-