getPatches | R Documentation |
Obtain patches of a graph by Rem's algorithm.
getPatches(bonds, nvertex)
bonds |
a matrix of bonds in a graph, with one bond per row. |
nvertex |
number of vertices in a graph. |
Given all bonds and the number of vertices in a graph, this function provides all patches.
A list comprises all patches in a graph. Each component of the list consists of vertices within one patch.
Edsger W. Dijkstra (1976) A Discipline of Programming Englewood Cliffs, New Jersey : Prentice-Hall, Inc
#Example 1: Find patches of a 3*3 2D graph with 6 bonds.
bonds <- matrix(c(1,2,2,5,5,6,3,6,5,8,7,8), ncol=2, byrow=TRUE)
getPatches(bonds, 9)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.