A triangle of an undirected graph is simply three vertices of the graph, u, v, and w, which are also connected by the edges (u, v), (v, w), and (w, u). Spatially, this arrangement looks like a triangle. Listing all of the triangles of a graph has a number of important applications in network analysis and knowledge discovery. For example, vertices with a high triangle count are usually extremely significant in social networks, such as Twitter, often associated with people who act as central figures in communities. This 2013 SIGMOD Best Paper Award winner deals with the problem of counting triangles in graphs that are too large to be stored entirely in the main memory.
The algorithm uses as input a graph whose edge list is sorted by source vertex, thereby clustering vertices of an edge together. The edge list is loaded sequentially, one chunk of edges at a time, into memory. This chunk is then compared to a scan of the entire edge list. The process identifies all triangles with one edge in the loaded chunk (say (u, v) in the example above) and the opposite vertex (w in the example above). This paper provides an algorithmic complexity analysis of both data movement from disk as well as of work done in the memory, showing that both are done efficiently by connecting the amount of work done to the arboricity of the graph.
The paper is a must-read for both theorists and practitioners in the large-scale graph processing area.