initial commit of stub of integer weight scaling algorithm

This commit is contained in:
eugenefischer
2025-03-27 13:42:27 -05:00
parent 5f5d77b0a4
commit 3d302cf8ad
5 changed files with 138 additions and 2 deletions

View File

@@ -582,7 +582,7 @@ public class InteractiveInterface {
boolean backToOptions = false;
while(!backToOptions) {
System.out.println("\n---------ALGORITHM OPTIONS----------");
System.out.println("1) Use scaling algorithm by Duan and Su.");
System.out.println("1) Use integer weight scaling algorithm by Duan and Su.");
System.out.println("2) Use Hungarian algorithm with Fibonacci heap priority queue");
System.out.println("3) Use Hungarian algorithm with pairing heap priority queue");
System.out.println("4) Use auction algorithm");
@@ -590,13 +590,19 @@ public class InteractiveInterface {
try {
input = sc.nextInt();
switch (input) {
case 1 -> System.out.println("This option is not yet implemented. Choose another.");
case 1 -> {
BiGpairSEQ.setIntegerWeightScalingAlgorithm();
System.out.println("MWM algorithm set to integer weight scaling algorithm of Duan and Su");
backToOptions = true;
}
case 2 -> {
BiGpairSEQ.setHungarianAlgorithm();
BiGpairSEQ.setFibonacciHeap();
System.out.println("MWM algorithm set to Hungarian with Fibonacci heap");
backToOptions = true;
}
case 3 -> {
BiGpairSEQ.setHungarianAlgorithm();
BiGpairSEQ.setPairingHeap();
System.out.println("MWM algorithm set to Hungarian with pairing heap");
backToOptions = true;