MathTop

graph_center 函数

返回离心率等于图半径的顶点。

语法

  • GraphTheory:-Center(edges)
  • graph_center(edges)

参数与选项

edges形如 [[u, v], ...] 的连通边列表。

示例

  1. 中心顶点GraphTheory:-Center([[a, b], [b, c], [c, d]])返回 [b, c]。