ShortestPathSpanningTree[g,v]
グラフ g の v から他のどの頂点への最短経路も木の経路であるように,v を根とする最短経路全域木を構築する.


ShortestPathSpanningTree
ShortestPathSpanningTree[g,v]
グラフ g の v から他のどの頂点への最短経路も木の経路であるように,v を根とする最短経路全域木を構築する.
詳細とオプション
- ShortestPathSpanningTreeの機能はWolfram言語の組込み関数FindSpanningTreeで利用できるようになった.
- ShortestPathSpanningTreeを使うためには,まず Combinatorica パッケージをロードしなくてはならない.それにはNeeds["Combinatorica`"]を実行する必要がある.
- 値Automatic,Dijkstra,BellmanFordのいずれかを取るオプションAlgorithmが提供される.これにより,DijkstraアルゴリズムとBellman–Fordアルゴリズムのどちらかを選ぶことができる.
- デフォルトはAlgorithm->Automaticである.この場合,辺が負の重みを持つかどうかにより,またグラフの密度に基づいて,アルゴリズムがBellmanFordかDijkstraを選択する.
例題
例 (2)
ShortestPathSpanningTreeの代りにFindSpanningTreeが使われるようになった:
テクニカルノート
テキスト
Wolfram Research (2012), ShortestPathSpanningTree, Wolfram言語関数, https://reference.wolfram.com/language/Combinatorica/ref/ShortestPathSpanningTree.html.
CMS
Wolfram Language. 2012. "ShortestPathSpanningTree." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/Combinatorica/ref/ShortestPathSpanningTree.html.
APA
Wolfram Language. (2012). ShortestPathSpanningTree. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/Combinatorica/ref/ShortestPathSpanningTree.html
BibTeX
@misc{reference.wolfram_2025_shortestpathspanningtree, author="Wolfram Research", title="{ShortestPathSpanningTree}", year="2012", howpublished="\url{https://reference.wolfram.com/language/Combinatorica/ref/ShortestPathSpanningTree.html}", note=[Accessed: 17-September-2025]}
BibLaTeX
@online{reference.wolfram_2025_shortestpathspanningtree, organization={Wolfram Research}, title={ShortestPathSpanningTree}, year={2012}, url={https://reference.wolfram.com/language/Combinatorica/ref/ShortestPathSpanningTree.html}, note=[Accessed: 17-September-2025]}