Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

edges2vees

List Dihedral Triples in a Graph


Description

Given a list of edges between vertices, compile a list of all ‘vees’ or dihedral triples formed by these edges.

Usage

edges2vees(iedge, jedge, nvert=max(iedge, jedge), ...,
                check=TRUE)

Arguments

iedge,jedge

Integer vectors, of equal length, specifying the edges.

nvert

Number of vertices in the network.

...

Ignored

check

Logical. Whether to check validity of input data.

Details

Given a finite graph with nvert vertices and with edges specified by iedge, jedge, this low-level function finds all ‘vees’ or ‘dihedral triples’ in the graph, that is, all triples of vertices (i,j,k) where i and j are joined by an edge and i and k are joined by an edge.

The interpretation of iedge, jedge is that each successive pair of entries specifies an edge in the graph. The kth edge joins vertex iedge[k] to vertex jedge[k]. Entries of iedge and jedge must be integers from 1 to nvert.

Value

A 3-column matrix of integers, in which each row represents a triple of vertices, with the first vertex joined to the other two vertices.

Author(s)

and Rolf Turner r.turner@auckland.ac.nz

See Also

Examples

i <- c(1, 2, 5, 5, 1, 4, 2)
 j <- c(2, 3, 3, 1, 3, 2, 5)
 edges2vees(i, j)

spatstat.geom

Geometrical Functionality of the 'spatstat' Family

v2.1-0
GPL (>= 2)
Authors
Adrian Baddeley [aut, cre], Rolf Turner [aut], Ege Rubak [aut], Tilman Davies [ctb], Ute Hahn [ctb], Abdollah Jalilian [ctb], Sebastian Meyer [ctb], Suman Rakshit [ctb], Dominic Schuhmacher [ctb], Rasmus Waagepetersen [ctb]
Initial release
2021-04-15

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.