Class BKSAcsMain

java.lang.Object
org.ddolib.examples.boundedknapsack.BKSAcsMain

public class BKSAcsMain extends Object
Bounded Knapsack Problem (BKS) with Acs. Main class for solving the Bounded Knapsack Problem (BKS) using an Anytime Column Search (ACS) approach.

This class demonstrates how to set up a BKS problem instance, define an ACS model, and solve the problem using the Solvers.minimizeAcs(AcsModel, java.util.function.BiConsumer) method. It also prints the solution and statistics to the console.

  • Constructor Details

    • BKSAcsMain

      public BKSAcsMain()
  • Method Details

    • main

      public static void main(String[] args)
      Entry point of the application.

      The method performs the following steps:

      1. Creates a BKS problem instance with 10 items, capacity 1000, and strongly correlated instance type.
      2. Defines an ACS model for the problem, including a lower bound and dominance checker.
      3. Solves the problem using an Ant Colony System (ACS) solver.
      4. Prints the solution and search statistics to the console.
      Parameters:
      args - command-line arguments (not used)