フィルターのクリア

MATLAB support for additional graph distance metrics/norms?

3 ビュー (過去 30 日間)
David Mittiga
David Mittiga 2020 年 8 月 22 日
コメント済み: David Mittiga 2020 年 8 月 26 日
I am attempting to compute the "shortest path tree" on a weighted graph but I need to use a different distance metric than usual. Rather than compute the distance along a path as the sum of the edge weights, I want to compute the distance as the maximum weight of the edges. This would be akin to using the infinity-norm instead of the one-norm.
After doing some research, it appears that MATLAB does not support this capability in its graph class. Rather, it only supports distance being calculated by the one-norm. Would you consider this for inclusion in a future MATLAB update? Can you recommend any work-arounds?
Thanks very much for your help!

採用された回答

Ayush Gupta
Ayush Gupta 2020 年 8 月 26 日
There is no specific function in MATLAB to incorporate various distance metrics while calculating shortest paths between two nodes. However, you can calculate all possible paths between two nodes and can refer this. After that we can iterate through the paths and find the maximum of each path. Lastly, we can compare these maximum and get the desired path.
  1 件のコメント
David Mittiga
David Mittiga 2020 年 8 月 26 日
Thanks for your reply! I have come up with a more efficient method for calculating the tree desired. I may post it to the file exchange.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGraph and Network Algorithms についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by