Postagens

Mostrando postagens de setembro, 2025

Flow network

Imagem
Given the flow network below with labels (capacity, flow), let (S) be the source and (T) be the sink. Build the residual network from the given (capacity, flow) labels. Consider this as the   initial residual network and evaluate the statements: I. In the initial residual network, the path S -> B -> E -> F -> T is an augmenting path with bottleneck 3 . II. In the initial residual network, there is no augmenting path. The current flow is already maximum. III. Starting from the initial residual network, after performing any best single-path augmentation (i.e., any   augmenting path   with maximum bottleneck possible) , there still exists an augmenting path with bottleneck 1 . IV. The value of the current flow in the given network (before any new augmentation) is 13 . Choose the correct alternative: A) I and III only B) I and IV only C) II and III only D) I, III, and IV E) None of the above Original idea by: Thiago Soares Laitz

Graph algorithms

A software engineering team is modernizing a legacy system with hundreds of code modules. The goal is to refactor the system by splitting it into independent microservices. A major challenge is the complex network of “imports” between modules. They found that many modules are interdependent; that is, Module A depends on Module B, which in turn, directly or indirectly, depends on Module A. To carry out the microservice separation, the team first needs to identify these groups of mutually dependent modules, since they must be treated as a single unit. Which algorithmic approach would be most effective to identify these groups of modules, considering this problem can be modeled as a directed graph? Analyze the statements below and select the correct alternative: I. Topological Sorting can be applied because it arranges modules in a linear order of dependencies and, when it fails, it indicates the existence of cycles, making it useful as a diagnostic tool and making it easy to identify th...