关于以下练习的问题:
设 N=(V,E,c,s,t) 为一个流网络,其中 (V,E) 无环,令 m=|E|。描述一个多项式时间算法,通过解 ≤ m+1 次最大流问题来检查 N 是否具有唯一的最大流。解释算法的正确性和运行时间。
我的建议如下:
run FF (Ford Fulkerson) once and save the value of the flow v(f) and the flow over all egdes f(e_i)
for each edge e_i with f(e_i)>0:
set capacity (in this iteration) of this edge c(e_i)=f(e_i)-1 and run FF.
If the value of the flow is the same as in the original graph, then there exists another way to push the max flow through the network and we're done - the max flow isn't unique --> return "not unique"
Otherwise we continue
we're done with looping without finding another max flow of same value, that means max flow is unique -> return "unique"
有任何反馈吗?我是否忽略了一些不适用的情况?