diff --git a/GraphVisualizer.cs b/GraphVisualizer.cs index e248c8cf6661aeb1db4a5832b12c1fe82fb97d27..ab4098e696b0f9d3a43dd7191b63a3d47efced91 100644 --- a/GraphVisualizer.cs +++ b/GraphVisualizer.cs @@ -21,10 +21,16 @@ public static class GraphVisualizer if (edge.IsBackwards) { msaglEdge.LabelText = $"{0}/{edge.Residual}"; + msaglEdge.Attr.Color = Color.Gray; } else { msaglEdge.LabelText = $"{edge.MaxFlow-edge.Residual}/{edge.MaxFlow}"; + + if (edge.MaxFlow-edge.Residual > 0) + { + msaglEdge.Attr.Color = Color.Orange; + } } } diff --git a/MainWindow.xaml.cs b/MainWindow.xaml.cs index edbe1677ced621f6b7860331c29f0712de9d40a2..dad6b5126b466e06f71cde9876bc17c2fb35ecff 100644 --- a/MainWindow.xaml.cs +++ b/MainWindow.xaml.cs @@ -130,6 +130,8 @@ namespace FlowForge double maxFlow = _fordFulkerson.Run("1", "4"); Console.WriteLine($"Maximaler Fluss von Quelle zu Senke: {maxFlow}"); + MessageBox.Show($"Maximaler Fluss von Quelle zu Senke: {maxFlow}"); + /* // Dictionary to store the flow along the augmenting path