bandwidth {RBGL} | R Documentation |
Compute bandwidth for an undirected graph
bandwidth(g)
g |
an instance of the graph class with edgemode
“undirected” |
The bandwidth of an undirected graph G=(V, E) is the maximum distance between two adjacent vertices, with distance measured on a line upon which the vertices have been placed at unit intervals. To put it another way, if the vertices of an undirected graph G=(V,E) are each assigned an index from zero to |V| - 1 given by index[v], then the bandwidth of G is
B(G) = max { |index[u] - index[v]| | (u,v) in E }
bandwidth |
the bandwidth of the given graph |
Li Long <li.long@isb-sib.ch>
Boost Graph Library by Siek et al.
coex <- fromGXL(file(system.file("XML/dijkex.gxl",package="RBGL"))) coex@edgemode <- "undirected" bandwidth(coex)