正在加载图片...
Weighted edges More general:each edge has a non-negative length. aA length function l(x,y)is given. l(path)=sum of lengths of edges on path l(s,t)=min l(path)over all paths from s to t Question:How to do now? Let's try BFS first. 24Weighted edges ◼ More general: each edge has a non-negative length. ❑ A length function 𝑙(𝑥, 𝑦) is given. ◼ 𝑙 𝑝𝑎𝑡ℎ = sum of lengths of edges on 𝑝𝑎𝑡ℎ ◼ 𝑙 𝑠,𝑡 = min 𝑙(𝑝𝑎𝑡ℎ) over all 𝑝𝑎𝑡ℎ𝑠 from 𝑠 to 𝑡 ◼ Question: How to do now? ◼ Let’s try BFS first. 24
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有