xgi.generators.simple#
Generators for some simple hypergraphs.
All the functions in this module return a Hypergraph class (i.e. a simple, undirected hypergraph).
Functions
- star_clique(n_star, n_clique, d_max)[source]#
Generate a star-clique structure
That is a star network and a clique network, connected by one pairwise edge connecting the centre of the star to the clique. network, the each clique is promoted to a hyperedge up to order d_max.
- Parameters:
n_star (int) – Number of legs of the star
n_clique (int) – Number of nodes in the clique
d_max (int) – Maximum order up to which to promote cliques to hyperedges
- Returns:
H
- Return type:
Examples
>>> import xgi >>> H = xgi.star_clique(6, 7, 2)
Notes
The total number of nodes is n_star + n_clique.