EdgeCost
更多信息
- 可以使用下列选项:
-
Automatic 自动确定边代价 "prop" 将注释 "prop" 作为代价使用 {vivj->cij,…} 边
具有代价
等{c1,c2,…} 按 EdgeList 使用的相同顺序给出所有边代价 {pattern->c,…} 匹配模式的边具有代价 w - 封装 Annotation[vivj,EdgeCost->c] 可以当使用诸如 Graph 等函数创建图时使用.
- 代价
可以是任意表达式. - 边代价对于不同图计算函数有特殊的含义.
范例
基本范例 (1)
EdgeCost 选项可将图中各边与代价相关联:
与边相关联的代价会影响函数的结果,如 FindMinimumCostFlow:
文本
Wolfram Research (2012),EdgeCost,Wolfram 语言函数,https://reference.wolfram.com/language/ref/EdgeCost.html.
CMS
Wolfram 语言. 2012. "EdgeCost." Wolfram 语言与系统参考资料中心. Wolfram Research. https://reference.wolfram.com/language/ref/EdgeCost.html.
APA
Wolfram 语言. (2012). EdgeCost. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/ref/EdgeCost.html 年
BibTeX
@misc{reference.wolfram_2025_edgecost, author="Wolfram Research", title="{EdgeCost}", year="2012", howpublished="\url{https://reference.wolfram.com/language/ref/EdgeCost.html}", note=[Accessed: 02-May-2026]}
BibLaTeX
@online{reference.wolfram_2025_edgecost, organization={Wolfram Research}, title={EdgeCost}, year={2012}, url={https://reference.wolfram.com/language/ref/EdgeCost.html}, note=[Accessed: 02-May-2026]}