pub fn random_nested_hypergraph(
n: usize,
m: usize,
d: usize,
epsilon: &NestedEpsilon,
seed: Option<u64>,
) -> Result<Hypergraph, GeneratorError>Available on crate feature
generators only.Expand description
Random nested hypergraph (Kim et al. 2023). XGI 1.1 random_nested_hypergraph(n, m, d, epsilon, seed).
Draws m distinct facets of d of the n nodes, adds every subset of size 2 to d of each facet, then
keeps each subset of size t < d with probability epsilon for t, and otherwise rewires it: one of its
nodes is kept and the others are replaced by t - 1 nodes drawn without replacement. The final edges are a
set, as in XGI: a repeated member set collapses. Edges are added in ascending order of their sorted members,
so ids never depend on a hash order. The same seed gives the same hypergraph; the draws are not XGI’s.
§Errors
GeneratorError::InvalidParameter when m > C(n, d) or epsilon has fewer than d - 2 values.