Wolfram Language & System 10.4 (2016)|Legacy Documentation

This is documentation for an earlier version of the Wolfram Language.
BUILT-IN WOLFRAM LANGUAGE SYMBOL

CompleteGraph

gives the complete graph with n vertices .

CompleteGraph[{n1,n2,,nk}]
gives the complete k-partite graph with vertices .

Details and OptionsDetails and Options

• CompleteGraph generates a Graph object.
• gives a graph with n vertices and an edge between every pair of vertices.
• CompleteGraph[{n1,n2,,nk}] gives a graph with vertices partitioned into disjoint sets with vertices each and edges between all vertices in different sets and , but no edges between vertices in the same set .
• gives a directed complete graph.
• CompleteGraph takes the same options as Graph.

ExamplesExamplesopen allclose all

Basic Examples  (4)Basic Examples  (4)

The first few complete graphs :

 In[1]:=
 Out[1]=

Bipartite graphs :

 In[1]:=
 Out[1]=

Directed complete graphs use two directional edges for each undirected edge:

 In[1]:=
 Out[1]=

Directed complete -partite graphs use directed edges from one group to another:

 In[1]:=
 Out[1]=