haskell-igraph-0.6.0: Haskell interface of the igraph library.

Safe HaskellNone
LanguageHaskell2010

IGraph.Generators

Synopsis

Documentation

full Source #

Arguments

:: SingI d 
=> Int

The number of vertices in the graph.

-> Bool

Whether to include self-edges (loops)

-> Graph d () () 

star Source #

Arguments

:: Int

The number of nodes

-> Graph U () () 

Return the Star graph. The center node is always associated with id 0.

erdosRenyiGame Source #

Arguments

:: SingI d 
=> ErdosRenyiModel 
-> Bool

self-loop

-> IO (Graph d () ()) 

degreeSequenceGame Source #

Arguments

:: [Int]

Out degree

-> [Int]

In degree

-> IO (Graph D () ()) 

Generates a random graph with a given degree sequence.

rewire Source #

Arguments

:: (Hashable v, Serialize v, Eq v, Serialize e) 
=> Int

Number of rewiring trials to perform.

-> Graph d v e 
-> IO (Graph d v e) 

Randomly rewires a graph while preserving the degree distribution.