Qurak

VertexCount

Khả dụng

Returns the number of vertices in a graph (optionally matching a pattern)

VertexCount[g]
VertexCount[g, patt]
VertexCount[{v -> w, …}, …]
g = HararyGraph[3, 5, VertexSize -> Large, ImagePadding -> 10]; vd = VertexDegree[g]; HighlightGraph[g, Table[Style[Labeled[VertexList[g][[i]], vd[[i]]], ColorData["TemperatureMap"][vd[[i]] / Max[vd]]], {i, VertexCount[g]}]]; VertexCount[g, _ ? (VertexDegree[g, #] == 3&)] → 4

Được dùng trong

Chủ đề

Liên quan

Tất cả 6300 hàm · Dùng cái này từ một client MCP